mirror of
https://github.com/Dispatcharr/Dispatcharr.git
synced 2026-07-18 00:55:50 +00:00
fixed store when adding channels in bulk
This commit is contained in:
parent
27845a88a1
commit
caca00ce30
1 changed files with 4 additions and 1 deletions
|
|
@ -48,7 +48,10 @@ const useChannelsStore = create((set) => ({
|
|||
set((state) => ({
|
||||
channels: {
|
||||
...state.channels,
|
||||
...newChannels,
|
||||
...newChannels.reduce((acc, channel) => {
|
||||
acc[channel.id] = channel;
|
||||
return acc;
|
||||
}, {}),
|
||||
},
|
||||
})),
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue