Skip to content

Commit

Permalink
auto: format code
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Dec 18, 2024
1 parent 8d6a243 commit b7c2d6a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion packages/openauth/src/adapter/code.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,11 @@ export function CodeAdapter<
) {
const fd = await c.req.formData()
const compare = fd.get("code")?.toString()
if (!state.code || !compare || !timingSafeCompare(state.code, compare)) {
if (
!state.code ||
!compare ||
!timingSafeCompare(state.code, compare)
) {
return transition(
c,
{
Expand Down
2 changes: 1 addition & 1 deletion packages/openauth/src/random.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ export function timingSafeCompare(a: string, b: string): boolean {
return false
}
return timingSafeEqual(Buffer.from(a), Buffer.from(b))
}
}

0 comments on commit b7c2d6a

Please sign in to comment.