mirror of
https://github.com/Unleash/unleash.git
synced 2025-01-31 00:16:47 +01:00
fix: filter duplicates
This commit is contained in:
parent
388dfe45d3
commit
8b18b8cca4
@ -25,7 +25,10 @@ export default class FlexibleRolloutStrategy extends Component {
|
||||
resolveStickiness = () => {
|
||||
const { context } = this.props;
|
||||
return builtInStickinessOptions.concat(
|
||||
context.filter(c => c.stickiness).map(c => ({ key: c.name, label: c.name }))
|
||||
context
|
||||
.filter(c => c.stickiness)
|
||||
.filter(c => !builtInStickinessOptions.find(s => s.key === c.name))
|
||||
.map(c => ({ key: c.name, label: c.name }))
|
||||
);
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user