File tree 1 file changed +9
-0
lines changed
libs/application-generic/src/services
1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,14 @@ import { NotificationStep } from '../usecases';
12
12
import { FeatureFlagsService } from './feature-flags' ;
13
13
14
14
export const DAY_IN_MS = 24 * 60 * 60 * 1000 ;
15
+ const DEMO_WORKFLOWS_IDENTIFIER = [
16
+ 'demo-apartment-review' ,
17
+ 'a-new-member-joining-the-team' ,
18
+ 'demo-verify-otp' ,
19
+ 'demo-password-reset' ,
20
+ 'demo-recent-login' ,
21
+ 'demo-comment-on-task' ,
22
+ ] ;
15
23
16
24
/* The absolute maximum values allowed by the system */
17
25
export const SYSTEM_LIMITS = {
@@ -62,6 +70,7 @@ export class ResourceValidatorService {
62
70
async validateWorkflowLimit ( environmentId : string ) : Promise < void > {
63
71
const workflowsCount = await this . notificationTemplateRepository . count ( {
64
72
_environmentId : environmentId ,
73
+ 'triggers.identifier' : { $nin : DEMO_WORKFLOWS_IDENTIFIER } ,
65
74
} ) ;
66
75
67
76
if ( workflowsCount < MIN_VALIDATION_LIMITS . WORKFLOWS ) {
You can’t perform that action at this time.
0 commit comments