Settings: Re-fetch users list every time

This commit is contained in:
Gustav Hansen 2023-02-27 08:42:09 +01:00
parent 52c7eba65b
commit bdac89a166
2 changed files with 0 additions and 4 deletions

View File

@ -53,8 +53,6 @@ const EditPage = ({ canUpdate }) => {
const { status, data } = useQuery(['user', id], () => fetchUser(id), { const { status, data } = useQuery(['user', id], () => fetchUser(id), {
retry: false, retry: false,
keepPreviousData: false,
staleTime: 1000 * 20,
onError(err) { onError(err) {
const status = err.response.status; const status = err.response.status;

View File

@ -70,9 +70,7 @@ const ListPage = () => {
const { status, data, isFetching } = useQuery(queryName, () => fetchData(search, notifyLoad), { const { status, data, isFetching } = useQuery(queryName, () => fetchData(search, notifyLoad), {
enabled: canRead, enabled: canRead,
keepPreviousData: true,
retry: false, retry: false,
staleTime: 1000 * 20,
onError() { onError() {
toggleNotification({ toggleNotification({
type: 'warning', type: 'warning',