1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-11-24 20:06:55 +01:00
unleash.unleash/src
Thomas Heartman 89a3578826
fix: allow external flag resolver to override false experiments with variants in getAll (#10966)
Fixes a bug / uncovered edge case in the flag resolver in Unleash:
If a local experiment was defined as false (the typical default value),
then that flag could only ever be returned as a boolean from the
`ui-config` endpoint. In other words, even if the external resolver has
a variant for that flag, the UI would never get the variant.

The fix is to not just check `isEnabled` for false flags, but instead:
- use `getVariant`
- then check `variant.enabled` (in which case we have a variant and can
return it)
- else check `variant.feature_enabled`, falling back to `isEnabled` only
if `feature_enabled` is null/undefined.
2025-11-12 12:00:27 +01:00
..
lib fix: allow external flag resolver to override false experiments with variants in getAll (#10966) 2025-11-12 12:00:27 +01:00
mailtemplates fix: health-technical debt trends in emails (#10308) 2025-07-04 16:46:59 +02:00
migrations feat: add safeguards migration (#10928) 2025-11-06 11:03:40 +02:00
test chore: remove release plans from getFeature endpoint (#10955) 2025-11-10 15:06:21 +02:00
migrator.ts chore: remove AWS IAM DB auth prototype code (#10662) 2025-09-12 14:46:28 +01:00
server-dev.ts chore(AI): trafficBillingDisplay flag cleanup (#10949) 2025-11-10 10:35:33 +02:00
server.ts feat: Unleash v7 ESM migration (#9877) 2025-05-14 09:47:12 +02:00
test-setup.ts task: migrate tests to vitest 2025-05-16 11:19:10 +02:00