Skip to content

Commit 9420141

Browse files
committed
merge with other command platforms and version when ignore
1 parent c564b9a commit 9420141

1 file changed

Lines changed: 10 additions & 1 deletion

File tree

editor/src/app/state/extensions/reducer.ts

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,16 @@ export const extensionsReducer = createReducer(
8080
(command) =>
8181
commandMatcher(command, newCommand, ignoreVersionAndPlatform),
8282
'id',
83-
() => (newCommand.id && newCommand.name ? newCommand : null),
83+
(c) =>
84+
newCommand.id && newCommand.name
85+
? ignoreVersionAndPlatform
86+
? {
87+
...newCommand,
88+
platforms: c.platforms,
89+
versions: c.versions,
90+
}
91+
: newCommand
92+
: null,
8493
() => (newCommand.id && newCommand.name ? newCommand : null)
8594
),
8695
}),

0 commit comments

Comments
 (0)