]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - plugins/GNUsocialPhotos/actions/editphoto.php
Merge branch 'nightly' into singpolyma/gnu-social-events-saveObjectFromActivity
[quix0rs-gnu-social.git] / plugins / GNUsocialPhotos / actions / editphoto.php
index 7ac8104ae8be87fdbbcec6da290ea48021068b97..35dac7bf3f6298d921d62f100ffdd8b7d6059e5b 100644 (file)
@@ -179,8 +179,7 @@ class EditphotoAction extends Action
             return;
         }
         common_redirect('/photo/' . $this->photo->id, '303');
-        $this->showForm(_('Success!'), true);
-
+        // common_redirect exits
     }
 
     function deletePhoto()
@@ -193,12 +192,11 @@ class EditphotoAction extends Action
         $this->photo->delete();
         
         if (Event::handle('StartDeleteOwnNotice', array($this->user, $notice))) {
-            $notice->delete();
+            $notice->deleteAs($this->scoped);
             Event::handle('EndDeleteOwnNotice', array($this->user, $notice));
         }
        $this->showForm(_('Success!'));
         common_redirect('/' . $this->user->nickname . '/photos/' . $oldalbum, '303');
-        return;
     }
 
 }