From e58a14de724da8f110525ba4faf5ecf8f006b3f5 Mon Sep 17 00:00:00 2001 From: dim0x69 Date: Mon, 11 Dec 2017 09:41:45 +0000 Subject: [PATCH] Check return value from Plugins --- classes/pref/feeds.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) mode change 100755 => 100644 classes/pref/feeds.php diff --git a/classes/pref/feeds.php b/classes/pref/feeds.php old mode 100755 new mode 100644 index fcbc0f8cd..2a9c57e79 --- a/classes/pref/feeds.php +++ b/classes/pref/feeds.php @@ -1739,9 +1739,13 @@ class Pref_Feeds extends Handler_Protected { } static function remove_feed($id, $owner_uid) { + $debug = isset($_REQUEST["debug"]); foreach (PluginHost::getInstance()->get_hooks(PluginHost::HOOK_UNSUBSCRIBE_FEED) as $p) { - $line = $p->hook_unsubscribe_feed($id, $owner_uid); + if( ! $p->hook_unsubscribe_feed($id, $owner_uid)){ + if($debug) _debug("Feed not removed due to Error in Plugin. (HOOK_UNSUBSCRIBE_FEED)"); + return; + } } if ($id > 0) {