summaryrefslogtreecommitdiff
path: root/actions/deletenotice.php
diff options
context:
space:
mode:
authorEvan Prodromou <evan@status.net>2010-09-08 16:37:12 -0400
committerEvan Prodromou <evan@status.net>2010-09-08 16:37:12 -0400
commit255e96d3b5cd86a1e7b4f759e4ab3088b195f005 (patch)
tree62e1c93eb3655b6652a53bd2c4435307b117c5a3 /actions/deletenotice.php
parente40ed1fd56bc02dbae20e0839c507911bc27cf4c (diff)
add a hook for when someone deletes their own notice
Diffstat (limited to 'actions/deletenotice.php')
-rw-r--r--actions/deletenotice.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/actions/deletenotice.php b/actions/deletenotice.php
index f8010a814..68c43040b 100644
--- a/actions/deletenotice.php
+++ b/actions/deletenotice.php
@@ -172,7 +172,10 @@ class DeletenoticeAction extends Action
}
if ($this->arg('yes')) {
- $this->notice->delete();
+ if (Event::handle('StartDeleteOwnNotice', array($this->user, $this->notice))) {
+ $this->notice->delete();
+ Event::handle('EndDeleteOwnNotice', array($this->user, $this->notice));
+ }
}
$url = common_get_returnto();