aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-03-13 13:43:26 +0100
committerChocobozzz <me@florianbigard.com>2020-03-13 14:54:00 +0100
commitbaab47ca81742deae15acd671e8c332a4e1d6eb7 (patch)
tree06838db49de28a3adae14934ef2d036e33b3bb8e /server/controllers
parent8c966daab30dd2bc8fd9792a8e219d94f3d8e67c (diff)
downloadPeerTube-baab47ca81742deae15acd671e8c332a4e1d6eb7.tar.gz
PeerTube-baab47ca81742deae15acd671e8c332a4e1d6eb7.tar.zst
PeerTube-baab47ca81742deae15acd671e8c332a4e1d6eb7.zip
Fix total videos stats
Diffstat (limited to 'server/controllers')
-rw-r--r--server/controllers/api/server/stats.ts11
1 files changed, 6 insertions, 5 deletions
diff --git a/server/controllers/api/server/stats.ts b/server/controllers/api/server/stats.ts
index 6d508a481..f6a85d0c0 100644
--- a/server/controllers/api/server/stats.ts
+++ b/server/controllers/api/server/stats.ts
@@ -26,11 +26,12 @@ async function getStats (req: express.Request, res: express.Response) {
26 const { totalInstanceFollowers, totalInstanceFollowing } = await ActorFollowModel.getStats() 26 const { totalInstanceFollowers, totalInstanceFollowing } = await ActorFollowModel.getStats()
27 const { totalLocalVideoFilesSize } = await VideoFileModel.getStats() 27 const { totalLocalVideoFilesSize } = await VideoFileModel.getStats()
28 28
29 const strategies: { strategy: VideoRedundancyStrategyWithManual, size: number }[] = CONFIG.REDUNDANCY.VIDEOS.STRATEGIES 29 const strategies = CONFIG.REDUNDANCY.VIDEOS.STRATEGIES
30 .map(r => ({ 30 .map(r => ({
31 strategy: r.strategy, 31 strategy: r.strategy as VideoRedundancyStrategyWithManual,
32 size: r.size 32 size: r.size
33 })) 33 }))
34
34 strategies.push({ strategy: 'manual', size: null }) 35 strategies.push({ strategy: 'manual', size: null })
35 36
36 const videosRedundancyStats = await Promise.all( 37 const videosRedundancyStats = await Promise.all(