unleash-client
Advanced tools
Comparing version 4.2.0 to 4.2.1
@@ -65,9 +65,3 @@ "use strict"; | ||
const feature = this.repository.getToggle(name); | ||
let enabled; | ||
if (!this.isParentDependencySatisfied(feature, context)) { | ||
enabled = false; | ||
} | ||
else { | ||
enabled = this.isFeatureEnabled(feature, context, fallback).enabled; | ||
} | ||
const enabled = this.isFeatureEnabled(feature, context, fallback).enabled; | ||
if (feature === null || feature === void 0 ? void 0 : feature.impressionData) { | ||
@@ -88,3 +82,3 @@ this.emit(events_2.UnleashEvents.Impression, (0, events_2.createImpressionEvent)({ | ||
} | ||
if (!feature || !feature.enabled) { | ||
if (!feature || !this.isParentDependencySatisfied(feature, context) || !feature.enabled) { | ||
return { enabled: false }; | ||
@@ -165,3 +159,3 @@ } | ||
const fallback = fallbackVariant || (0, variant_1.getDefaultVariant)(); | ||
if (typeof feature === 'undefined' || !this.isParentDependencySatisfied(feature, context)) { | ||
if (typeof feature === 'undefined') { | ||
return { ...fallback, featureEnabled: false }; | ||
@@ -168,0 +162,0 @@ } |
@@ -1,1 +0,1 @@ | ||
{ "name": "unleash-client-node", "version": "4.2.0", "sdkVersion": "unleash-client-node:4.2.0" } | ||
{ "name": "unleash-client-node", "version": "4.2.1", "sdkVersion": "unleash-client-node:4.2.1" } |
{ | ||
"name": "unleash-client", | ||
"version": "4.2.0", | ||
"version": "4.2.1", | ||
"description": "Unleash Client for Node", | ||
@@ -5,0 +5,0 @@ "license": "Apache-2.0", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
216305
2740