Honour the (now legacy) enableLabs flag
parent
f5f0c7e715
commit
f94873bd5d
|
@ -36,9 +36,16 @@ export default {
|
||||||
getLabsFeatures() {
|
getLabsFeatures() {
|
||||||
const featuresConfig = SdkConfig.get()['features'] || {};
|
const featuresConfig = SdkConfig.get()['features'] || {};
|
||||||
|
|
||||||
|
// The old flag: honourned for backwards compat
|
||||||
|
const enableLabs = SdkConfig.get()['enableLabs'];
|
||||||
|
|
||||||
return FEATURES.filter((f) => {
|
return FEATURES.filter((f) => {
|
||||||
|
if (enableLabs) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
const sdkConfigValue = featuresConfig[f.id];
|
const sdkConfigValue = featuresConfig[f.id];
|
||||||
if (!['enable', 'disable'].includes(sdkConfigValue)) {
|
if (sdkConfigValue === 'labs') {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}).map((f) => {
|
}).map((f) => {
|
||||||
|
|
Loading…
Reference in New Issue