Automatically start feed update when adding new feed

This commit is contained in:
Aurimas Vinckevicius 2015-02-03 11:56:27 -06:00 committed by Dan Stillman
parent 2c3eb205ab
commit e7f568d56c

View file

@ -866,7 +866,7 @@ var ZoteroPane = new function()
return collection.saveTx(); return collection.saveTx();
}); });
this.newFeed = function() { this.newFeed = Zotero.Promise.coroutine(function() {
let data = {}; let data = {};
window.openDialog('chrome://zotero/content/feedSettings.xul', window.openDialog('chrome://zotero/content/feedSettings.xul',
null, 'centerscreen, modal', data); null, 'centerscreen, modal', data);
@ -876,9 +876,10 @@ var ZoteroPane = new function()
feed.name = data.title; feed.name = data.title;
feed.refreshInterval = data.ttl; feed.refreshInterval = data.ttl;
feed.cleanupAfter = data.cleanAfter; feed.cleanupAfter = data.cleanAfter;
feed.save({skipEditCheck: true}); yield feed.save({skipEditCheck: true});
} Zotero.Feeds.scheduleNextFeedCheck();
} }
});
this.newGroup = function () { this.newGroup = function () {
this.loadURI(Zotero.Groups.addGroupURL); this.loadURI(Zotero.Groups.addGroupURL);