Merge branch 'master' of github.com:jeena/FeedMonkey

This commit is contained in:
Jeena 2014-05-22 20:20:11 +02:00
commit e120f99e4e
5 changed files with 68 additions and 20 deletions

View file

@ -69,15 +69,15 @@ Pond.prototype.doOperation = function(method, operation, new_options, callback)
};
Pond.prototype.reload = function(callback) {
Pond.prototype.reload = function(callback,limit) {
var _this = this;
this.getFeeds(function() { _this.getUnreadFeeds(callback); });
this.getFeeds(function() { _this.getUnreadFeeds(callback,0,limit); });
};
Pond.prototype.getUnreadFeeds = function(callback, skip) {
Pond.prototype.getUnreadFeeds = function(callback, skip, limit) {
var options = {
status: "unread",
limit: 100
limit: limit || 100
};
if(skip && skip.length > 0) {
@ -224,4 +224,4 @@ Pond.login = function(server_url, user, password, callback) {
xhr.setRequestHeader("Content-Length", options.length);
xhr.setRequestHeader("Connection", "close");
xhr.send(options);
}
}