diff options
author | Chocobozzz <me@florianbigard.com> | 2021-11-16 11:17:52 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-11-16 11:34:24 +0100 |
commit | 3455c2656e257ae3d9b4169af58b6889d9904148 (patch) | |
tree | 72ef7035ffd9030cffe8e73d7c1265241c120173 /server/lib/video-views.ts | |
parent | ac03618098e430acb21c075bdba57ce6d377b12d (diff) | |
download | PeerTube-3455c2656e257ae3d9b4169af58b6889d9904148.tar.gz PeerTube-3455c2656e257ae3d9b4169af58b6889d9904148.tar.zst PeerTube-3455c2656e257ae3d9b4169af58b6889d9904148.zip |
Test and log request retries
Diffstat (limited to 'server/lib/video-views.ts')
-rw-r--r-- | server/lib/video-views.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/server/lib/video-views.ts b/server/lib/video-views.ts index 220b509c2..c024eb93c 100644 --- a/server/lib/video-views.ts +++ b/server/lib/video-views.ts | |||
@@ -1,3 +1,4 @@ | |||
1 | import { isTestInstance } from '@server/helpers/core-utils' | ||
1 | import { logger, loggerTagsFactory } from '@server/helpers/logger' | 2 | import { logger, loggerTagsFactory } from '@server/helpers/logger' |
2 | import { VIEW_LIFETIME } from '@server/initializers/constants' | 3 | import { VIEW_LIFETIME } from '@server/initializers/constants' |
3 | import { VideoModel } from '@server/models/video/video' | 4 | import { VideoModel } from '@server/models/video/video' |
@@ -98,7 +99,7 @@ export class VideoViews { | |||
98 | } | 99 | } |
99 | 100 | ||
100 | private async cleanViewers () { | 101 | private async cleanViewers () { |
101 | logger.info('Cleaning video viewers.', lTags()) | 102 | if (!isTestInstance()) logger.info('Cleaning video viewers.', lTags()) |
102 | 103 | ||
103 | for (const videoId of this.viewersPerVideo.keys()) { | 104 | for (const videoId of this.viewersPerVideo.keys()) { |
104 | const notBefore = new Date().getTime() | 105 | const notBefore = new Date().getTime() |