Skip to content

Commit

Permalink
tidy up
Browse files Browse the repository at this point in the history
  • Loading branch information
j4w8n-malynium committed Aug 1, 2023
1 parent cc29371 commit 33b8ce3
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions src/lib/browser/storage.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
import type { SupportedStorage } from '@supabase/supabase-js'
import { getSupabaseLoadClientCookieOptions } from '../config/index.js'
import { isBrowser, isAuthToken } from '../utils.js'
import { serialize } from 'cookie'
import { base } from '$app/paths'

let token = ''
Expand Down Expand Up @@ -57,19 +55,6 @@ export const CookieStorage: SupportedStorage = {
} else {
csrf = setCsrf()

/**
* If this is the first visit or the page refreshes,
* set a temp non-httpOnly cookie for use with initial endpoint calls.
*/
// const cookie_options = getSupabaseLoadClientCookieOptions()
// document.cookie = serialize(`sb-${csrf.name}-csrf`, csrf.token, {
// ...cookie_options,
// httpOnly: false,
// maxAge: 5,
// sameSite: 'strict',
// secure: true
// })

try {
const res = await fetch(csrf_route, {
method: 'POST',
Expand Down

0 comments on commit 33b8ce3

Please sign in to comment.