mirror of
https://github.com/Unleash/unleash.git
synced 2025-01-11 00:08:30 +01:00
fix: check variants before mapping (#1922)
* fix: check variants before mapping * fix: default to empty array
This commit is contained in:
parent
c8f0283049
commit
c82318d4c5
@ -19,7 +19,7 @@ export const mapFeaturesForBootstrap = (
|
|||||||
features.map((feature) => ({
|
features.map((feature) => ({
|
||||||
impressionData: false,
|
impressionData: false,
|
||||||
...feature,
|
...feature,
|
||||||
variants: feature.variants.map((variant) => ({
|
variants: (feature.variants || []).map((variant) => ({
|
||||||
overrides: [],
|
overrides: [],
|
||||||
...variant,
|
...variant,
|
||||||
payload: variant.payload && {
|
payload: variant.payload && {
|
||||||
|
Loading…
Reference in New Issue
Block a user