Skip to content

Commit c6c5f3f

Browse files
jsjoeiocode-asher
andauthored
fixup
Co-authored-by: Asher <[email protected]>
1 parent 1b84811 commit c6c5f3f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/node/util.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -260,9 +260,8 @@ export type IsCookieValidArgs = {
260260
}
261261

262262
/** Checks if a req.cookies.key is valid using the PasswordMethod */
263-
export async function isCookieValid(isCookieValidArgs: IsCookieValidArgs): Promise<boolean> {
263+
export async function isCookieValid({ passwordFromArgs = "", cookieKey, hashedPasswordFromArgs = "" }: IsCookieValidArgs): Promise<boolean> {
264264
let isValid = false
265-
const { passwordFromArgs = "", cookieKey, hashedPasswordFromArgs = "" } = isCookieValidArgs
266265
switch (isCookieValidArgs.passwordMethod) {
267266
case "PLAIN_TEXT":
268267
isValid = await isHashMatch(passwordFromArgs, cookieKey)

0 commit comments

Comments
 (0)