aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-05-07 10:39:09 +0200
committerChocobozzz <me@florianbigard.com>2020-05-07 10:39:09 +0200
commit3cc665f48fd233d09f778d7e887488dde6f03ef6 (patch)
treeba8503723206ef17f4b8e4a2e40125472b28dbaf /server/controllers
parentee8e602ef9761b4869e14d4d3ed24a2e18f22c65 (diff)
downloadPeerTube-3cc665f48fd233d09f778d7e887488dde6f03ef6.tar.gz
PeerTube-3cc665f48fd233d09f778d7e887488dde6f03ef6.tar.zst
PeerTube-3cc665f48fd233d09f778d7e887488dde6f03ef6.zip
Add last login date to users
Diffstat (limited to 'server/controllers')
-rw-r--r--server/controllers/api/server/stats.ts8
1 files changed, 7 insertions, 1 deletions
diff --git a/server/controllers/api/server/stats.ts b/server/controllers/api/server/stats.ts
index f6a85d0c0..f07301a04 100644
--- a/server/controllers/api/server/stats.ts
+++ b/server/controllers/api/server/stats.ts
@@ -22,7 +22,7 @@ statsRouter.get('/stats',
22async function getStats (req: express.Request, res: express.Response) { 22async function getStats (req: express.Request, res: express.Response) {
23 const { totalLocalVideos, totalLocalVideoViews, totalVideos } = await VideoModel.getStats() 23 const { totalLocalVideos, totalLocalVideoViews, totalVideos } = await VideoModel.getStats()
24 const { totalLocalVideoComments, totalVideoComments } = await VideoCommentModel.getStats() 24 const { totalLocalVideoComments, totalVideoComments } = await VideoCommentModel.getStats()
25 const { totalUsers } = await UserModel.getStats() 25 const { totalUsers, totalDailyActiveUsers, totalWeeklyActiveUsers, totalMonthlyActiveUsers } = await UserModel.getStats()
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
@@ -48,9 +48,15 @@ async function getStats (req: express.Request, res: express.Response) {
48 totalLocalVideoComments, 48 totalLocalVideoComments,
49 totalVideos, 49 totalVideos,
50 totalVideoComments, 50 totalVideoComments,
51
51 totalUsers, 52 totalUsers,
53 totalDailyActiveUsers,
54 totalWeeklyActiveUsers,
55 totalMonthlyActiveUsers,
56
52 totalInstanceFollowers, 57 totalInstanceFollowers,
53 totalInstanceFollowing, 58 totalInstanceFollowing,
59
54 videosRedundancy: videosRedundancyStats 60 videosRedundancy: videosRedundancyStats
55 } 61 }
56 62