diff --git a/import_map.json b/import_map.json index ee102014d..a5f788492 100644 --- a/import_map.json +++ b/import_map.json @@ -16,6 +16,6 @@ "stripe": "https://esm.sh/stripe@12.6.0", "feed": "https://esm.sh/feed@4.2.2", "fresh_charts/": "https://deno.land/x/fresh_charts@0.2.1/", - "deno_kv_oauth": "https://deno.land/x/deno_kv_oauth@v0.1.6-beta/mod.ts" + "deno_kv_oauth": "https://deno.land/x/deno_kv_oauth@v0.1.8-beta/mod.ts" } } diff --git a/routes/callback.ts b/routes/callback.ts index c387ce8e8..0f63d6abc 100644 --- a/routes/callback.ts +++ b/routes/callback.ts @@ -32,9 +32,12 @@ async function getUser(accessToken: string): Promise { // deno-lint-ignore no-explicit-any export const handler: Handlers = { async GET(req) { - const { response, tokens, sessionId } = await handleCallback(req, client); + const { response, accessToken, sessionId } = await handleCallback( + req, + client, + ); - const githubUser = await getUser(tokens.accessToken); + const githubUser = await getUser(accessToken); const user = await getUserById(githubUser.id.toString()); if (!user) {