Skip to content

Commit

Permalink
fix pagination currentPage should be 0 if no pages
Browse files Browse the repository at this point in the history
  • Loading branch information
marshallswain committed Apr 30, 2020
1 parent 6434679 commit 9093409
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/FeathersVuexPagination.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export default {
get() {
const params = props.value
if (params) {
return params.$skip / params.$limit + 1
return pageCount.value === 0 ? 0 : params.$skip / params.$limit + 1
} else {
return 1
}
Expand Down

0 comments on commit 9093409

Please sign in to comment.