queue: { position:'end', scope: 'FEEDL-' + feed, limit: 1 } } );
}
- var unread_ctr = document.getElementById("FEEDU-" + feed);
+ var unread_ctr = get_feed_unread(feed);
var cache_check = false;
- if (unread_ctr && !page_offset && !force_nocache && !subop) {
- unread_ctr = unread_ctr.innerHTML;
+ if (unread_ctr != -1 && !page_offset && !force_nocache && !subop) {
var cache_prefix = "";
}
}
+function get_feed_unread(id) {
+ try {
+ return parseInt(document.getElementById("FEEDU-" + id).innerHTML);
+ } catch (e) {
+ exception_error("get_feed_unread", e, true);
+ return -1;
+ }
+}
+
function get_feed_entry_unread(doc, elem) {
var id = elem.id.replace("FEEDR-", "");