Skip to content

Commit

Permalink
merge with other command platforms and version when ignore
Browse files Browse the repository at this point in the history
  • Loading branch information
x87 committed Feb 20, 2022
1 parent c564b9a commit 9420141
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion editor/src/app/state/extensions/reducer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,16 @@ export const extensionsReducer = createReducer(
(command) =>
commandMatcher(command, newCommand, ignoreVersionAndPlatform),
'id',
() => (newCommand.id && newCommand.name ? newCommand : null),
(c) =>
newCommand.id && newCommand.name
? ignoreVersionAndPlatform
? {
...newCommand,
platforms: c.platforms,
versions: c.versions,
}
: newCommand
: null,
() => (newCommand.id && newCommand.name ? newCommand : null)
),
}),
Expand Down

0 comments on commit 9420141

Please sign in to comment.