mirror of
https://github.com/Unleash/unleash.git
synced 2025-09-28 17:55:15 +02:00
chore: flag cleanup simplifyDisableFeature (#9892)
This commit is contained in:
parent
7ca79c1b84
commit
1166d00e6d
@ -792,7 +792,6 @@ class FeatureToggleService {
|
|||||||
auditUser: IAuditUser,
|
auditUser: IAuditUser,
|
||||||
user?: IUser,
|
user?: IUser,
|
||||||
): Promise<void> {
|
): Promise<void> {
|
||||||
if (this.flagResolver.isEnabled('simplifyDisableFeature')) {
|
|
||||||
const strategies =
|
const strategies =
|
||||||
await this.featureStrategiesStore.getStrategiesForFeatureEnv(
|
await this.featureStrategiesStore.getStrategiesForFeatureEnv(
|
||||||
projectId,
|
projectId,
|
||||||
@ -812,25 +811,6 @@ class FeatureToggleService {
|
|||||||
user,
|
user,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
return;
|
|
||||||
}
|
|
||||||
const feature = await this.getFeature({ featureName });
|
|
||||||
|
|
||||||
const env = feature.environments.find((e) => e.name === environment);
|
|
||||||
const hasOnlyDisabledStrategies = env?.strategies.every(
|
|
||||||
(strategy) => strategy.disabled,
|
|
||||||
);
|
|
||||||
|
|
||||||
if (hasOnlyDisabledStrategies) {
|
|
||||||
await this.unprotectedUpdateEnabled(
|
|
||||||
projectId,
|
|
||||||
featureName,
|
|
||||||
environment,
|
|
||||||
false,
|
|
||||||
auditUser,
|
|
||||||
user,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
async unprotectedUpdateStrategy(
|
async unprotectedUpdateStrategy(
|
||||||
|
@ -61,7 +61,6 @@ export type IFlagKey =
|
|||||||
| 'consumptionModel'
|
| 'consumptionModel'
|
||||||
| 'teamsIntegrationChangeRequests'
|
| 'teamsIntegrationChangeRequests'
|
||||||
| 'edgeObservability'
|
| 'edgeObservability'
|
||||||
| 'simplifyDisableFeature'
|
|
||||||
| 'adminNavUI'
|
| 'adminNavUI'
|
||||||
| 'tagTypeColor'
|
| 'tagTypeColor'
|
||||||
| 'addEditStrategy'
|
| 'addEditStrategy'
|
||||||
@ -295,10 +294,6 @@ const flags: IFlags = {
|
|||||||
process.env.EXPERIMENTAL_EDGE_OBSERVABILITY,
|
process.env.EXPERIMENTAL_EDGE_OBSERVABILITY,
|
||||||
false,
|
false,
|
||||||
),
|
),
|
||||||
simplifyDisableFeature: parseEnvVarBoolean(
|
|
||||||
process.env.EXPERIMENTAL_SIMPLIFY_DISABLE_FEATURE,
|
|
||||||
false,
|
|
||||||
),
|
|
||||||
adminNavUI: parseEnvVarBoolean(
|
adminNavUI: parseEnvVarBoolean(
|
||||||
process.env.UNLEASH_EXPERIMENTAL_ADMIN_NAV_UI,
|
process.env.UNLEASH_EXPERIMENTAL_ADMIN_NAV_UI,
|
||||||
false,
|
false,
|
||||||
|
@ -55,7 +55,6 @@ process.nextTick(async () => {
|
|||||||
uniqueSdkTracking: true,
|
uniqueSdkTracking: true,
|
||||||
filterExistingFlagNames: true,
|
filterExistingFlagNames: true,
|
||||||
teamsIntegrationChangeRequests: true,
|
teamsIntegrationChangeRequests: true,
|
||||||
simplifyDisableFeature: true,
|
|
||||||
adminNavUI: true,
|
adminNavUI: true,
|
||||||
tagTypeColor: true,
|
tagTypeColor: true,
|
||||||
newStrategyDropdown: true,
|
newStrategyDropdown: true,
|
||||||
|
Loading…
Reference in New Issue
Block a user