Skip to content

Commit 8929d58

Browse files
author
Matt Carroll
committed
Fix
1 parent 02837e5 commit 8929d58

File tree

1 file changed

+4
-5
lines changed
  • packages/optimizely-sdk/lib/core/project_config

1 file changed

+4
-5
lines changed

packages/optimizely-sdk/lib/core/project_config/index.js

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -98,16 +98,15 @@ module.exports = {
9898
fns.forEach(feature.experimentIds || [], function(experimentId) {
9999
// Add this experiment in experiment-feature map.
100100
if (projectConfig.experimentFeatureMap[experimentId]) {
101-
projectConfig.experimentFeatureMap[experimentId].push(feature.id);
101+
projectConfig.experimentFeatureMap[experimentId].push(feature.id);
102102
} else {
103103
projectConfig.experimentFeatureMap[experimentId] = [feature.id];
104104
}
105-
105+
106106
var experimentInFeature = projectConfig.experimentIdMap[experimentId];
107-
if (experimentInFeature.groupId) {
107+
// Experiments in feature can only belong to one mutex group.
108+
if (experimentInFeature.groupId && !feature.groupId) {
108109
feature.groupId = experimentInFeature.groupId;
109-
// Experiments in feature can only belong to one mutex group.
110-
return false;
111110
}
112111
});
113112
});

0 commit comments

Comments
 (0)