Skip to content
This repository has been archived by the owner on May 17, 2018. It is now read-only.

Commit

Permalink
Fix #32
Browse files Browse the repository at this point in the history
  • Loading branch information
wyuenho committed Jan 20, 2013
1 parent f203dee commit a5ab20f
Show file tree
Hide file tree
Showing 4 changed files with 53 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/backbone-pageable.js
Original file line number Diff line number Diff line change
Expand Up @@ -695,7 +695,7 @@
hasPrevious: function () {
var self = this, state = self.state;
var currentPage = state.currentPage;
if (self.mode != "infinite") return currentPage >= state.firstPage;
if (self.mode != "infinite") return currentPage > state.firstPage;
return !!self.links[currentPage - 1];
},

Expand All @@ -706,7 +706,7 @@
hasNext: function () {
var self = this, state = self.state;
var currentPage = self.state.currentPage;
if (self.mode != "infinite") return currentPage <= state.lastPage;
if (self.mode != "infinite") return currentPage < state.lastPage;
return !!self.links[currentPage + 1];
},

Expand Down
Loading

0 comments on commit a5ab20f

Please sign in to comment.