summaryrefslogtreecommitdiff
path: root/contrib/feed-browser/update.php
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/feed-browser/update.php')
-rw-r--r--contrib/feed-browser/update.php10
1 files changed, 8 insertions, 2 deletions
diff --git a/contrib/feed-browser/update.php b/contrib/feed-browser/update.php
index 53317ebb03..98751ea26c 100644
--- a/contrib/feed-browser/update.php
+++ b/contrib/feed-browser/update.php
@@ -46,9 +46,15 @@ if(!check_database())
$feeds = db_query("SELECT f_id, f_name, f_uri FROM feeds");
-if($argc > 1 AND $argv[1] == 'upgrades')
+if($argc == 2)
{
- $feeds = db_query("SELECT f_id, f_name, f_uri FROM feeds WHERE f_type = 'upgrades'");
+ $feeds = db_query("SELECT f_id, f_name, f_uri FROM feeds WHERE f_uri = '${argv[1]}'");
+} else if ($argc == 3 && $argv[1] == "--type") {
+ $feeds = db_query("SELECT f_id, f_name, f_uri FROM feeds WHERE f_type = '${argv[2]}'");
+}
+
+if (!$feeds) {
+ die("Cannot find feed(s) in the DB\n");
}
$start = time();