]> git.wh0rd.org Git - tt-rss.git/commitdiff
rssfuncs: load pluginhost stuff properly
authorAndrew Dolgov <fox@madoka.volgo-balt.ru>
Sat, 23 Feb 2013 14:40:48 +0000 (18:40 +0400)
committerAndrew Dolgov <fox@madoka.volgo-balt.ru>
Sat, 23 Feb 2013 14:40:48 +0000 (18:40 +0400)
include/rssfuncs.php

index af9a8b65c1431fea846063e6e6da6c6beec1dd08..a1ddbb740fabac7780bfe6bbd562dad6c2ff4a30 100644 (file)
                }
 
                $pluginhost = new PluginHost($link);
+               $user_plugins = get_pref($link, "_ENABLED_PLUGINS", $owner_uid);
+
+               $pluginhost->load(PLUGINS, $pluginhost::KIND_ALL);
+               $pluginhost->load($user_plugins, $pluginhost::KIND_USER, $owner_uid);
+               $pluginhost->load_data();
 
                foreach ($pluginhost->get_hooks($pluginhost::HOOK_FEED_FETCHED) as $plugin) {
                        $feed_data = $plugin->hook_feed_fetched($feed_data);
                if (!$rss->error()) {
 
                        // We use local pluginhost here because we need to load different per-user feed plugins
-                       $user_plugins = get_pref($link, "_ENABLED_PLUGINS", $owner_uid);
-
-                       $pluginhost->load(PLUGINS, $pluginhost::KIND_ALL);
-                       $pluginhost->load($user_plugins, $pluginhost::KIND_USER, $owner_uid);
-                       $pluginhost->load_data();
-
                        $pluginhost->run_hooks($pluginhost::HOOK_FEED_PARSED, "hook_feed_parsed", $rss);
 
                        if ($debug_enabled) {