mirror of
https://github.com/supabase/supabase.git
synced 2026-10-05 17:35:10 +03:00
docs: Fix hono issues (#45798)
## I have read the [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) file. YES <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Refactor** * Simplified cookie handling in the Supabase SSR authentication middleware by streamlining the `setAll` handler to focus exclusively on cookie management, removing additional header manipulation from the response. [](https://app.coderabbit.ai/change-stack/supabase/supabase/pull/45798) <!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
1 parent
84268aa810
commit
f95d978cbc
1 file changed
+1
-2
@@ -38,9 +38,8 @@ export const supabaseMiddleware = (): MiddlewareHandler => {
|
||||
getAll() {
|
||||
return parseCookieHeader(c.req.header('Cookie') ?? '')
|
||||
},
|
||||
setAll(cookiesToSet, cacheHeaders) {
|
||||
setAll(cookiesToSet) {
|
||||
cookiesToSet.forEach(({ name, value, options }) => setCookie(c, name, value, options))
|
||||
Object.entries(cacheHeaders).forEach(([key, value]) => c.header(key, value))
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
Reference in new issue
Block a user