aboutsummaryrefslogtreecommitdiff
path: root/engine
diff options
context:
space:
mode:
authorCash Costello <cash.costello@gmail.com>2011-12-23 19:31:27 -0500
committerCash Costello <cash.costello@gmail.com>2011-12-23 19:31:27 -0500
commit9e311e7236188e826277aed3dca733e02eb21f6a (patch)
tree2ce75390add0a732c7523ebce82ccaebf39ef4f4 /engine
parente3100d350c27804f80de3321b00be9dfc23c6d2a (diff)
downloadelgg-9e311e7236188e826277aed3dca733e02eb21f6a.tar.gz
elgg-9e311e7236188e826277aed3dca733e02eb21f6a.tar.bz2
Fixes #683 not deleting annotation when event handlers return false on an update
Diffstat (limited to 'engine')
-rw-r--r--engine/lib/annotations.php8
1 files changed, 2 insertions, 6 deletions
diff --git a/engine/lib/annotations.php b/engine/lib/annotations.php
index bfd40d1e8..6e0402804 100644
--- a/engine/lib/annotations.php
+++ b/engine/lib/annotations.php
@@ -163,13 +163,9 @@ function update_annotation($annotation_id, $name, $value, $value_type, $owner_gu
where id=$annotation_id and $access");
if ($result !== false) {
+ // @todo add plugin hook that sends old and new annotation information before db access
$obj = elgg_get_annotation_from_id($annotation_id);
- if (elgg_trigger_event('update', 'annotation', $obj)) {
- return true;
- } else {
- // @todo add plugin hook that sends old and new annotation information before db access
- elgg_delete_annotation_by_id($annotation_id);
- }
+ elgg_trigger_event('update', 'annotation', $obj);
}
return $result;