aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/helpers/custom-validators/video-lives.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/helpers/custom-validators/video-lives.ts')
-rw-r--r--server/helpers/custom-validators/video-lives.ts11
1 files changed, 11 insertions, 0 deletions
diff --git a/server/helpers/custom-validators/video-lives.ts b/server/helpers/custom-validators/video-lives.ts
new file mode 100644
index 000000000..69d08ae68
--- /dev/null
+++ b/server/helpers/custom-validators/video-lives.ts
@@ -0,0 +1,11 @@
1import { LiveVideoLatencyMode } from '@shared/models'
2
3function isLiveLatencyModeValid (value: any) {
4 return [ LiveVideoLatencyMode.DEFAULT, LiveVideoLatencyMode.SMALL_LATENCY, LiveVideoLatencyMode.HIGH_LATENCY ].includes(value)
5}
6
7// ---------------------------------------------------------------------------
8
9export {
10 isLiveLatencyModeValid
11}