Skip to content

Commit 9227f4e

Browse files
committed
Update Feature Flags for new plans
1 parent 16759ed commit 9227f4e

File tree

4 files changed

+5
-55
lines changed

4 files changed

+5
-55
lines changed

backend/src/api/conversation/conversationSettingsUpdate.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
import Error403 from '../../errors/Error403'
2-
import isFeatureEnabled from '../../feature-flags/isFeatureEnabled'
32
import Permissions from '../../security/permissions'
43
import ConversationService from '../../services/conversationService'
54
import PermissionChecker from '../../services/user/permissionChecker'
6-
import { FeatureFlag } from '../../types/common'
75

86
export default async (req, res) => {
97
new PermissionChecker(req).validateHas(Permissions.values.conversationEdit)
108

11-
if (req.body.customUrl && !(await isFeatureEnabled(FeatureFlag.COMMUNITY_HELP_CENTER_PRO, req))) {
9+
if (req.body.customUrl) {
1210
await req.responseHandler.error(
1311
req,
1412
res,

backend/src/bin/scripts/unleash-init.ts

Lines changed: 0 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -65,17 +65,6 @@ const constaintConfiguration = {
6565
},
6666
],
6767
],
68-
[FeatureFlag.COMMUNITY_HELP_CENTER_PRO]: [
69-
[
70-
{
71-
values: [Plans.values.growth],
72-
inverted: false,
73-
operator: 'IN',
74-
contextName: 'plan',
75-
caseInsensitive: false,
76-
},
77-
],
78-
],
7968
[FeatureFlag.CSV_EXPORT]: [
8069
[
8170
{
@@ -197,23 +186,6 @@ const constaintConfiguration = {
197186
caseInsensitive: false,
198187
},
199188
],
200-
[
201-
{
202-
values: [Plans.values.essential],
203-
inverted: false,
204-
operator: 'IN',
205-
contextName: 'plan',
206-
caseInsensitive: false,
207-
},
208-
{
209-
value: PLAN_LIMITS[Plans.values.essential][FeatureFlag.MEMBER_ENRICHMENT].toString(),
210-
values: [],
211-
inverted: false,
212-
operator: 'NUM_LT',
213-
contextName: 'memberEnrichmentCount',
214-
caseInsensitive: false,
215-
},
216-
],
217189
],
218190
[FeatureFlag.ORGANIZATION_ENRICHMENT]: [
219191
[
@@ -250,23 +222,6 @@ const constaintConfiguration = {
250222
caseInsensitive: false,
251223
},
252224
],
253-
[
254-
{
255-
values: [Plans.values.essential],
256-
inverted: false,
257-
operator: 'IN',
258-
contextName: 'plan',
259-
caseInsensitive: false,
260-
},
261-
{
262-
value: PLAN_LIMITS[Plans.values.essential][FeatureFlag.ORGANIZATION_ENRICHMENT].toString(),
263-
values: [],
264-
inverted: false,
265-
operator: 'NUM_LT',
266-
contextName: 'organizationEnrichmentCount',
267-
caseInsensitive: false,
268-
},
269-
],
270225
],
271226
[FeatureFlag.SEGMENTS]: [],
272227
}

backend/src/feature-flags/isFeatureEnabled.ts

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@ export const PLAN_LIMITS = {
99
[Plans.values.essential]: {
1010
[FeatureFlag.AUTOMATIONS]: 2,
1111
[FeatureFlag.CSV_EXPORT]: 2,
12-
[FeatureFlag.MEMBER_ENRICHMENT]: 5,
13-
[FeatureFlag.ORGANIZATION_ENRICHMENT]: 5,
1412
},
1513
[Plans.values.growth]: {
1614
[FeatureFlag.AUTOMATIONS]: 10,
@@ -19,10 +17,10 @@ export const PLAN_LIMITS = {
1917
[FeatureFlag.ORGANIZATION_ENRICHMENT]: 200,
2018
},
2119
[Plans.values.scale]: {
22-
[FeatureFlag.AUTOMATIONS]: 100,
23-
[FeatureFlag.CSV_EXPORT]: 100,
24-
[FeatureFlag.MEMBER_ENRICHMENT]: 10000,
25-
[FeatureFlag.ORGANIZATION_ENRICHMENT]: 2000,
20+
[FeatureFlag.AUTOMATIONS]: 20,
21+
[FeatureFlag.CSV_EXPORT]: 20,
22+
[FeatureFlag.MEMBER_ENRICHMENT]: Infinity,
23+
[FeatureFlag.ORGANIZATION_ENRICHMENT]: Infinity,
2624
},
2725
[Plans.values.enterprise]: {
2826
[FeatureFlag.AUTOMATIONS]: Infinity,

backend/src/types/common.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ export interface SearchCriteria {
1919

2020
export enum FeatureFlag {
2121
AUTOMATIONS = 'automations',
22-
COMMUNITY_HELP_CENTER_PRO = 'community-help-center-pro',
2322
EAGLE_EYE = 'eagle-eye',
2423
CSV_EXPORT = 'csv-export',
2524
LINKEDIN = 'linkedin',

0 commit comments

Comments
 (0)