Initial Version
This commit is contained in:
10
core/src/utils/helpers/fetch-wrapper.ts
Normal file
10
core/src/utils/helpers/fetch-wrapper.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
import { useUserStore } from '@KTXC/stores/userStore';
|
||||
import { createFetchWrapper } from './fetch-wrapper-core';
|
||||
|
||||
// Create fetch wrapper with user store logout callback
|
||||
export const fetchWrapper = createFetchWrapper({
|
||||
onLogout: () => {
|
||||
const { logout } = useUserStore();
|
||||
logout();
|
||||
}
|
||||
});
|
||||
Reference in New Issue
Block a user