Skip to content

Commit

Permalink
Merge branch 'feat/new-user-panel-all' into feat/new-user-panel-pending
Browse files Browse the repository at this point in the history
  • Loading branch information
rique223 authored Mar 22, 2024
2 parents 3a5004e + 5b74149 commit 05544d4
Showing 1 changed file with 0 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,18 +50,13 @@ const useFilteredUsers = ({ searchTerm, prevSearchTerm, sortData, paginationData
offset: searchTerm === prevSearchTerm.current ? current : 0,
};
}, [current, itemsPerPage, prevSearchTerm, searchTerm, setCurrent, sortBy, sortDirection, tab]);

const getUsers = useEndpoint('GET', '/v1/users.listByStatus');

const dispatchToastMessage = useToastMessageDispatch();

const usersListQueryResult = useQuery(['users.list', payload, tab], async () => getUsers(payload), {
onError: (error) => {
dispatchToastMessage({ type: 'error', message: error });
},
});

return usersListQueryResult;
};

export default useFilteredUsers;

0 comments on commit 05544d4

Please sign in to comment.