Just some comment clarification

This commit is contained in:
Mikael Nordfeldth 2016-03-21 17:50:06 +01:00
parent 86ce93b376
commit 55544845db

View File

@ -87,7 +87,8 @@ class ActivityModerationPlugin extends ActivityVerbHandlerPlugin
} }
public function onDeleteNoticeAsProfile(Notice $stored, Profile $actor, &$result) { public function onDeleteNoticeAsProfile(Notice $stored, Profile $actor, &$result) {
// By adding a new 'delete' verb we will eventually trigger $this->saveObjectFromActivity // By adding a new object with the 'delete' verb we will trigger
// $this->saveObjectFromActivity that will do the actual ->delete()
if (false === Deleted_notice::addNew($stored, $actor)) { if (false === Deleted_notice::addNew($stored, $actor)) {
// false is returned if we did not have an error, but did not create the object // false is returned if we did not have an error, but did not create the object
// (i.e. the author is currently being deleted) // (i.e. the author is currently being deleted)
@ -95,8 +96,8 @@ class ActivityModerationPlugin extends ActivityVerbHandlerPlugin
} }
// We return false (to stop the event) if the deleted_notice entry was // We return false (to stop the event) if the deleted_notice entry was
// added, which means we have run $this->saveObjectFromActivity which // added, which means we have already run $this->saveObjectFromActivity
// in turn has called the delete function of the notice. // which in turn has called the delete function of the notice.
return false; return false;
} }