diff options
author | Chocobozzz <me@florianbigard.com> | 2020-01-08 14:15:16 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2020-01-08 14:15:16 +0100 |
commit | fe98765624cdd6695739bda719fcb726b71c2b2a (patch) | |
tree | 18b19d427e5c25fc9e5290062f307e668f4c9e45 /server/controllers/bots.ts | |
parent | ddc07312b041c1c533b68a919681fc9bce83430d (diff) | |
download | PeerTube-fe98765624cdd6695739bda719fcb726b71c2b2a.tar.gz PeerTube-fe98765624cdd6695739bda719fcb726b71c2b2a.tar.zst PeerTube-fe98765624cdd6695739bda719fcb726b71c2b2a.zip |
Add ability to skip count query
Diffstat (limited to 'server/controllers/bots.ts')
-rw-r--r-- | server/controllers/bots.ts | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/server/controllers/bots.ts b/server/controllers/bots.ts index ed1040176..f3e778b04 100644 --- a/server/controllers/bots.ts +++ b/server/controllers/bots.ts | |||
@@ -61,17 +61,18 @@ async function getSitemapAccountUrls () { | |||
61 | } | 61 | } |
62 | 62 | ||
63 | async function getSitemapLocalVideoUrls () { | 63 | async function getSitemapLocalVideoUrls () { |
64 | const resultList = await VideoModel.listForApi({ | 64 | const { data } = await VideoModel.listForApi({ |
65 | start: 0, | 65 | start: 0, |
66 | count: undefined, | 66 | count: undefined, |
67 | sort: 'createdAt', | 67 | sort: 'createdAt', |
68 | includeLocalVideos: true, | 68 | includeLocalVideos: true, |
69 | nsfw: buildNSFWFilter(), | 69 | nsfw: buildNSFWFilter(), |
70 | filter: 'local', | 70 | filter: 'local', |
71 | withFiles: false | 71 | withFiles: false, |
72 | countVideos: false | ||
72 | }) | 73 | }) |
73 | 74 | ||
74 | return resultList.data.map(v => ({ | 75 | return data.map(v => ({ |
75 | url: WEBSERVER.URL + '/videos/watch/' + v.uuid, | 76 | url: WEBSERVER.URL + '/videos/watch/' + v.uuid, |
76 | video: [ | 77 | video: [ |
77 | { | 78 | { |