Skip to content

Commit

Permalink
[chore]: const variable name set
Browse files Browse the repository at this point in the history
  • Loading branch information
VictoryJu committed Sep 18, 2024
1 parent e300bad commit e7b9ab9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/hooks/api/useChat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ export const useChatRoomMessages = (params: ReqChatRoomMessages) => {
return useQuery({
queryKey: chatKeys.chatMessagesKey(params),
queryFn: async ({ queryKey }) => {
const reqChatRoomMessages = queryKey[1];
const queryKeyParamsIndex = 1;
const reqChatRoomMessages = queryKey[queryKeyParamsIndex];
const res = await fetchChatRoomMessages(reqChatRoomMessages);
return res;
},
Expand Down

0 comments on commit e7b9ab9

Please sign in to comment.