File tree Expand file tree Collapse file tree 3 files changed +8
-7
lines changed Expand file tree Collapse file tree 3 files changed +8
-7
lines changed Original file line number Diff line number Diff line change 1
1
import type { LoaderFunction } from "@remix-run/node" ;
2
2
import { authenticator } from "~/services/auth.server" ;
3
- import { redirectCookie } from "./auth.github" ;
3
+ import { redirectCookie } from "./auth.github.server " ;
4
4
import { logger } from "~/services/logger.server" ;
5
5
6
6
export let loader : LoaderFunction = async ( { request } ) => {
Original file line number Diff line number Diff line change
1
+ import { createCookie } from "@remix-run/node" ;
2
+
3
+ export const redirectCookie = createCookie ( "redirect-to" , {
4
+ maxAge : 60 * 60 , // 1 hour
5
+ httpOnly : true ,
6
+ } ) ;
Original file line number Diff line number Diff line change 1
1
import type { ActionFunction , LoaderFunction } from "@remix-run/node" ;
2
- import { createCookie } from "@remix-run/node" ;
3
2
import { redirect } from "@remix-run/node" ;
4
3
import { authenticator } from "~/services/auth.server" ;
4
+ import { redirectCookie } from "./auth.github.server" ;
5
5
6
6
export let loader : LoaderFunction = ( ) => redirect ( "/login" ) ;
7
7
@@ -27,8 +27,3 @@ export let action: ActionFunction = async ({ request }) => {
27
27
throw error ;
28
28
}
29
29
} ;
30
-
31
- export const redirectCookie = createCookie ( "redirect-to" , {
32
- maxAge : 60 * 60 , // 1 hour
33
- httpOnly : true ,
34
- } ) ;
You can’t perform that action at this time.
0 commit comments