sap-cf-features
Advanced tools
Comparing version 0.0.2 to 0.0.3
@@ -27,3 +27,7 @@ "use strict"; | ||
const allFlags = yield exportFlags(); | ||
return allFlags.flags.filter((flag) => flag.enabled).map((flag) => flag.id); | ||
return allFlags.flags | ||
// remove the filter here, because there is something wrong with boolean features | ||
// boolean features that are active are always true. they should only be true when the feature is released no? | ||
// .filter( (flag) => flag.enabled ) | ||
.map((flag) => flag.id); | ||
}); | ||
@@ -49,4 +53,7 @@ } | ||
return __awaiter(this, void 0, void 0, function* () { | ||
if (names.length === 0) { | ||
return {}; | ||
} | ||
const service = getService(); | ||
const url = `/api/v2/evaluateset?${names.map(getFlags).join('&')}&identifier=${tenant}`; | ||
const url = `/api/v2/evaluateset?${names.map(getFlags).join('&')}&identifier=${tenant || ""}`; | ||
const response = yield axios_1.default.get(url, { | ||
@@ -53,0 +60,0 @@ url, |
{ | ||
"name": "sap-cf-features", | ||
"version": "0.0.2", | ||
"version": "0.0.3", | ||
"description": "Read SAP CF feature flags in nodejs", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
10993
220