From b302c80dc0d9ba8eabef9ef6576efe36afc57584 Mon Sep 17 00:00:00 2001 From: Wicklow <123956049+wickloww@users.noreply.github.com> Date: Fri, 7 Apr 2023 08:09:54 +0000 Subject: feature/ability to disable video history by default (#5728) * draft: ability to disable video history by default * Update configuration and add tests * Updated code based on review comments * Add tests on registration and video quota * Remove required video quotas in query * Fix tests --- shared/server-commands/server/config-command.ts | 5 +++++ shared/server-commands/users/users-command.ts | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) (limited to 'shared/server-commands') diff --git a/shared/server-commands/server/config-command.ts b/shared/server-commands/server/config-command.ts index eb6bb95a5..303fcab88 100644 --- a/shared/server-commands/server/config-command.ts +++ b/shared/server-commands/server/config-command.ts @@ -350,6 +350,11 @@ export class ConfigCommand extends AbstractCommand { enabled: true }, user: { + history: { + videos: { + enabled: true + } + }, videoQuota: 5242881, videoQuotaDaily: 318742 }, diff --git a/shared/server-commands/users/users-command.ts b/shared/server-commands/users/users-command.ts index 8a42fafc8..5b39d3488 100644 --- a/shared/server-commands/users/users-command.ts +++ b/shared/server-commands/users/users-command.ts @@ -165,8 +165,8 @@ export class UsersCommand extends AbstractCommand { username, adminFlags, password = 'password', - videoQuota = 42000000, - videoQuotaDaily = -1, + videoQuota, + videoQuotaDaily, role = UserRole.USER } = options -- cgit v1.2.3