projects
/
oweals
/
peertube.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
efb9afc
)
Server: fix videos pagination
author
Chocobozzz
<florian.bigard@gmail.com>
Wed, 6 Jul 2016 17:57:47 +0000
(19:57 +0200)
committer
Chocobozzz
<florian.bigard@gmail.com>
Wed, 6 Jul 2016 17:57:47 +0000
(19:57 +0200)
server/models/video.js
patch
|
blob
|
history
diff --git
a/server/models/video.js
b/server/models/video.js
index 1c06e477cc195c7a842799ff8c70af1d39c72a7a..8054caa773fc667b298dcdc06e0b19fb25e19bdd 100644
(file)
--- a/
server/models/video.js
+++ b/
server/models/video.js
@@
-248,7
+248,7
@@
function findWithCount (query, start, count, sort, callback) {
async.parallel([
function (asyncCallback) {
- self.find(query).skip(start).limit(
start +
count).sort(sort).exec(asyncCallback)
+ self.find(query).skip(start).limit(count).sort(sort).exec(asyncCallback)
},
function (asyncCallback) {
self.count(query, asyncCallback)