summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2015-07-04 19:33:46 +0300
committerAndrew Dolgov <[email protected]>2015-07-04 19:33:46 +0300
commit6bb96beb3a9fe1ff8b6f042787496ae594ad6370 (patch)
tree0be3669f90826ccaf174526a0fcd13bd675e0f49
parentb6714c77d2f94e9aa847b12d19dfe4897e559088 (diff)
update_rss_feed: set basic feed info if title is [Unknown] (fixes batch subscribe)
-rw-r--r--include/rssfuncs.php11
1 files changed, 11 insertions, 0 deletions
diff --git a/include/rssfuncs.php b/include/rssfuncs.php
index 7a3ea7402..8797ee523 100644
--- a/include/rssfuncs.php
+++ b/include/rssfuncs.php
@@ -291,6 +291,17 @@
_debug_suppress(!$debug_enabled);
_debug("start", $debug_enabled);
+ $result = db_query("SELECT title FROM ttrss_feeds
+ WHERE id = '$feed'");
+ $title = db_fetch_result($result, 0, "title");
+
+ // feed was batch-subscribed or something, we need to get basic info
+ // this is not optimal currently as it fetches stuff separately TODO: optimize
+ if ($title == "[Unknown]") {
+ _debug("setting basic feed info for $feed...");
+ set_basic_feed_info($feed);
+ }
+
$result = db_query("SELECT id,update_interval,auth_login,
feed_url,auth_pass,cache_images,
mark_unread_on_update, owner_uid,