Skip to content

Commit

Permalink
fix: revert CHANNEL_LIST_PARAMS_UPDATED payload
Browse files Browse the repository at this point in the history
  • Loading branch information
bang9 committed Dec 8, 2023
1 parent 9d8d8b3 commit 53b8a8f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/modules/ChannelList/dux/actionTypes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ type CHANNEL_LIST_PAYLOAD_TYPES = {
[CHANNEL_REPLACED_TO_TOP]: GroupChannel;
[CHANNEL_LIST_PARAMS_UPDATED]: {
channelListQuery: GroupChannelListQuery;
currentUserId?: string,
};
};

Expand Down
1 change: 1 addition & 0 deletions src/modules/ChannelList/dux/reducers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,7 @@ export default function channelListReducer(
.with({ type: channelListActions.CHANNEL_LIST_PARAMS_UPDATED }, (action) => ({
...state,
channelListQuery: action.payload.channelListQuery,
currentUserId: action.payload.currentUserId,
}))
.otherwise(() => state)
);
Expand Down
1 change: 1 addition & 0 deletions src/modules/ChannelList/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,7 @@ function setupChannelList({
type: channelActions.CHANNEL_LIST_PARAMS_UPDATED,
payload: {
channelListQuery,
currentUserId: sdk?.currentUser?.userId ?? '',
},
});
}
Expand Down

0 comments on commit 53b8a8f

Please sign in to comment.