remove some debugs
This commit is contained in:
parent
0cbcab6597
commit
ff10228907
4 changed files with 1 additions and 3 deletions
|
@ -8,6 +8,7 @@ export function initClient(): ApiClient {
|
|||
const client = createClient<paths>({ baseUrl: import.meta.env.VITE_API_URL })
|
||||
const UnauthorizedHandlerMiddleware: Middleware = {
|
||||
async onResponse({ response }) {
|
||||
console.debug('on response middleware?')
|
||||
console.debug(response.headers.getSetCookie())
|
||||
console.debug(response.headers.get('set-cookie'))
|
||||
if (response.status === 401) {
|
||||
|
|
|
@ -12,7 +12,6 @@ export default function LogoutPage({ authService }: LogoutPageProps) {
|
|||
const user = useUser()
|
||||
|
||||
useEffect(() => {
|
||||
console.debug(user)
|
||||
if (!user) {
|
||||
navigate('/login')
|
||||
}
|
||||
|
|
|
@ -2,7 +2,6 @@ import { FemtoApp } from '../types'
|
|||
import { produce } from 'immer'
|
||||
|
||||
export function setGlobal<K extends keyof FemtoApp>(k: K, v: FemtoApp[K]) {
|
||||
console.debug('setting global', k, v)
|
||||
window.$femto = produce(window.$femto ?? {}, (draft) => {
|
||||
draft[k] = v
|
||||
})
|
||||
|
|
|
@ -23,7 +23,6 @@ export function initUser() {
|
|||
|
||||
function updateUser() {
|
||||
globalUser = getUserFromCookie()
|
||||
console.debug('got user from cookie', globalUser)
|
||||
setGlobal('user', globalUser)
|
||||
dispatchMessage('user:updated', globalUser)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue