From db8393d0bbc1108b01e09fdd3f601434c5a83d81 Mon Sep 17 00:00:00 2001 From: Roman Date: Tue, 13 Aug 2024 05:14:12 +0300 Subject: [PATCH] fix type issues --- frontend/src/slices/channelsSlice.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/slices/channelsSlice.js b/frontend/src/slices/channelsSlice.js index abb0e28..47f9621 100644 --- a/frontend/src/slices/channelsSlice.js +++ b/frontend/src/slices/channelsSlice.js @@ -17,7 +17,7 @@ const slice = createSlice({ state.channelsList.push(payload); /* eslint-disable-line */ }, removeChannel: (state, { payload }) => { - if (payload.id === state.currentChannelId) { /* eslint-disable-line */ + if (+payload.id === +state.currentChannelId) { /* eslint-disable-line */ state.currentChannelId = 1; /* eslint-disable-line */ } const index = state.channelsList.findIndex((channel) => channel.id === payload.id);