parse_counters: cache feedlist after update (2)

This commit is contained in:
Andrew Dolgov 2009-02-02 16:36:37 +03:00
parent 4f7743a938
commit 3e2937fc21
2 changed files with 10 additions and 5 deletions

View File

@ -579,10 +579,11 @@ function parse_counters(reply, scheduled_call) {
setTimeout('updateFeedList(false, false)', 50); setTimeout('updateFeedList(false, false)', 50);
} }
} else { } else {
var fl = document.getElementById("feeds-frame").innerHTML;
if (fl) {
cache_invalidate("FEEDLIST"); cache_invalidate("FEEDLIST");
cache_inject("FEEDLIST", cache_inject("FEEDLIST", fl, getInitParam("num_feeds"));
document.getElementById("feedList").innerHTML, }
getInitParam("num_feeds"));
} }
} catch (e) { } catch (e) {

View File

@ -514,10 +514,14 @@ function init_second_stage() {
if (fl) { if (fl) {
render_feedlist(fl); render_feedlist(fl);
if (document.getElementById("feedList")) {
request_counters(); request_counters();
} else { } else {
setTimeout('updateFeedList(false, false)', 50); setTimeout('updateFeedList(false, false)', 50);
} }
} else {
setTimeout('updateFeedList(false, false)', 50);
}
debug("second stage ok"); debug("second stage ok");