Fixes duplicated transmissions and not working undo of like/dislike

This commit is contained in:
Michael 2018-10-27 11:09:23 +00:00
commit 73f596cc46
7 changed files with 30 additions and 43 deletions

View file

@ -691,9 +691,6 @@ function photos_post(App $a)
$arr['target'] .= '<link>' . xmlify('<link rel="alternate" type="text/html" href="' . System::baseUrl() . '/photos/' . $owner_record['nickname'] . '/image/' . $p[0]['resource-id'] . '" />' . "\n" . '<link rel="preview" type="'.$p[0]['type'].'" href="' . System::baseUrl() . "/photo/" . $p[0]['resource-id'] . '-' . $best . '.' . $ext . '" />') . '</link></target>';
$item_id = Item::insert($arr);
if ($item_id) {
Worker::add(PRIORITY_HIGH, "Notifier", "tag", $item_id);
}
}
}
}
@ -919,10 +916,6 @@ function photos_post(App $a)
// Update the photo albums cache
Photo::clearAlbumCache($page_owner_uid);
if ($visible) {
Worker::add(PRIORITY_HIGH, "Notifier", 'wall-new', $item_id);
}
Addon::callHooks('photo_post_end', $item_id);
// addon uploaders should call "killme()" [e.g. exit] within the photo_post_end hook