]> git.wh0rd.org - tt-rss.git/blobdiff - include/rssfuncs.php
Merge branch 'master' into tunable-fetches
[tt-rss.git] / include / rssfuncs.php
index 3bce14d33ab8786bd3b67bb8b7aa6a0a94fbbef8..ce197156c4603110d4c6c8d92f629fd16c5004ee 100644 (file)
                                        _debug("update_rss_feed: fetching [$fetch_url] (ts: $cache_timestamp/$last_updated_timestamp)");
                                }
 
+                               $force_refetch = isset($_REQUEST["force_refetch"]);
+
                                $feed_data = fetch_file_contents($fetch_url, false,
-                                       $auth_login, $auth_pass, false, $no_cache ? 15 : 45,
-                                       max($last_updated_timestamp, $cache_timestamp));
+                                       $auth_login, $auth_pass, false, 
+                                       $no_cache ? FEED_FETCH_NO_CACHE_TIMEOUT : FEED_FETCH_TIMEOUT,
+                                       $force_refetch ? 0 : max($last_updated_timestamp, $cache_timestamp));
 
                                if ($debug_enabled) {
                                        _debug("update_rss_feed: fetch done.");
                        if ($filter_match) {
                                foreach ($filter["actions"] AS $action) {
                                        array_push($matches, $action);
+
+                                       // if Stop action encountered, perform no further processing
+                                       if ($action["type"] == "stop") return $matches;
                                }
                        }
                }