From 55fccc895d8a7b2b339eeca973431202ab3a7ba2 Mon Sep 17 00:00:00 2001 From: Tom Moor Date: Wed, 21 Feb 2024 18:09:40 -0500 Subject: [PATCH] Remove max domains restriction on self-hosted --- server/models/TeamDomain.ts | 4 ++++ shared/validations.ts | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/server/models/TeamDomain.ts b/server/models/TeamDomain.ts index 1447d26f7..857d2c433 100644 --- a/server/models/TeamDomain.ts +++ b/server/models/TeamDomain.ts @@ -61,6 +61,10 @@ class TeamDomain extends IdModel< @BeforeCreate static async checkLimit(model: TeamDomain) { + if (!env.isCloudHosted) { + return; + } + const count = await this.count({ where: { teamId: model.teamId }, }); diff --git a/shared/validations.ts b/shared/validations.ts index fefe84704..c6a7a7056 100644 --- a/shared/validations.ts +++ b/shared/validations.ts @@ -49,7 +49,7 @@ export const PinValidation = { }; export const TeamValidation = { - /** The maximum number of domains per team */ + /** The maximum number of domains per team on cloud hosted */ maxDomains: 10, };