mirror of
https://github.com/strapi/strapi.git
synced 2025-07-30 04:20:34 +00:00
Settings: Re-fetch users list every time
This commit is contained in:
parent
52c7eba65b
commit
bdac89a166
@ -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;
|
||||||
|
|
||||||
|
@ -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',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user