Skip to content
Closed
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions server/api/auth/atproto.get.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@
if (!query.code) {
try {
const handle = query.handle?.toString()
const create = query.create?.toString()

Check failure on line 71 in server/api/auth/atproto.get.ts

View workflow job for this annotation

GitHub Actions / 💪 Type check

'create' is declared but its value is never read.

if (!handle) {
throw createError({
Expand All @@ -76,12 +76,7 @@
message: 'Handle not provided in query',
})
}

const redirectUrl = await atclient.authorize(handle, {
scope,
prompt: create ? 'create' : undefined,
})
return sendRedirect(event, redirectUrl.toString())
return "this api works"
} catch (error) {
const message = error instanceof Error ? error.message : 'Authentication failed.'

Expand Down
Loading