Correction mise à jour jeton authentification
This commit is contained in:
@ -33,7 +33,7 @@ export const useAddTrainMutation = ({ auth, onPostSuccess, onError }: TrainProps
|
||||
}).then(resp => resp.json())
|
||||
},
|
||||
onSuccess: async (data) => {
|
||||
if (data.error) {
|
||||
if (data.statusCode) {
|
||||
if (onError)
|
||||
onError({ response: data })
|
||||
return
|
||||
|
Reference in New Issue
Block a user