From: Andrew Dolgov Date: Tue, 12 Aug 2014 15:36:29 +0000 (+0400) Subject: update stored article after filter has finished processing to prevent plugins from... X-Git-Tag: 1.14~40 X-Git-Url: https://git.wh0rd.org/?p=tt-rss.git;a=commitdiff_plain;h=0084f0d1ba81522b243bb3b9138334ba0a7d2f00 update stored article after filter has finished processing to prevent plugins from reverting changes of earlier invoked plugins (experimental) --- diff --git a/include/rssfuncs.php b/include/rssfuncs.php index cdc490cb..f657f841 100644 --- a/include/rssfuncs.php +++ b/include/rssfuncs.php @@ -687,6 +687,12 @@ foreach ($pluginhost->get_hooks(PluginHost::HOOK_ARTICLE_FILTER) as $plugin) { $article = $plugin->hook_article_filter($article); + + $article["stored"] = array("title" => $article["title"], + "content" => $article["content"], + "link" => $article["link"], + "tags" => $article["tags"], + "author" => $article["author"]); } $entry_tags = $article["tags"]; @@ -697,7 +703,6 @@ $entry_plugin_data = db_escape_string($article["plugin_data"]); $entry_content = $article["content"]; // escaped below - _debug("plugin data: $entry_plugin_data", $debug_enabled); if ($cache_images && is_writable(CACHE_DIR . '/images'))