1
0
mirror of https://github.com/Unleash/unleash.git synced 2024-12-22 19:07:54 +01:00

fix: include strategy variants in the event log (#4716)

This commit is contained in:
Mateusz Kwasniewski 2023-09-14 13:23:11 +02:00 committed by GitHub
parent f68b0ad001
commit c2b068e28f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 0 deletions

View File

@ -409,6 +409,7 @@ class FeatureToggleService {
disabled: featureStrategy.disabled,
constraints: featureStrategy.constraints || [],
parameters: featureStrategy.parameters,
variants: featureStrategy.variants || [],
sortOrder: featureStrategy.sortOrder,
segments: segments.map((segment) => segment.id) ?? [],
};
@ -1285,6 +1286,7 @@ class FeatureToggleService {
name: strategy.strategyName,
constraints: strategy.constraints || [],
parameters: strategy.parameters,
variants: strategy.variants || [],
segments: [],
title: strategy.title,
disabled: strategy.disabled,

View File

@ -145,6 +145,7 @@ test('Should be able to get strategy by id', async () => {
const config: Omit<FeatureStrategySchema, 'id'> = {
name: 'default',
constraints: [],
variants: [],
parameters: {},
title: 'some-title',
};