From 41b82aa4b98bc0e2004e7d28c2f5933fbe3ad7a3 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Mon, 24 Dec 2012 14:27:15 +0400 Subject: add HOOK_UPDATE_TASK --- update.php | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) (limited to 'update.php') diff --git a/update.php b/update.php index d039d062e..f1396f6e6 100755 --- a/update.php +++ b/update.php @@ -51,7 +51,6 @@ print " -feedbrowser - update feedbrowser\n"; print " -daemon - start single-process update daemon\n"; print " -cleanup-tags - perform tags table maintenance\n"; - print " -get-feeds - receive popular feeds from linked instances\n"; print " -import USER FILE - import articles from XML\n"; print " -quiet - don't show messages\n"; print " -indexes - recreate missing schema indexes\n"; @@ -98,7 +97,8 @@ $rc = cleanup_tags($link, 14, 50000); _debug("Cleaned $rc cached tags."); - get_linked_feeds($link); + global $pluginhost; + $pluginhost->run_hooks($pluginhost::HOOK_UPDATE_TASK, "hook_update_task", $op); } if (in_array("-feedbrowser", $op)) { @@ -135,7 +135,8 @@ _debug("Cleaned $rc cached tags."); - get_linked_feeds($link); + global $pluginhost; + $pluginhost->run_hooks($pluginhost::HOOK_UPDATE_TASK, "hook_update_task", $op); } } @@ -145,10 +146,6 @@ _debug("$rc tags deleted.\n"); } - if (in_array("-get-feeds", $op)) { - get_linked_feeds($link); - } - if (in_array("-import",$op)) { $username = $argv[count($argv) - 2]; $filename = $argv[count($argv) - 1]; -- cgit v1.2.3-54-g00ecf