Compare commits

..

6 Commits

Author SHA1 Message Date
Milo Schwartz
d27ecaae5e Merge pull request #77 from fosrl/hotfix-2
remove double createHttpError
2025-01-17 22:00:25 -05:00
Milo Schwartz
f0898613a2 remove double createHttpError 2025-01-17 21:59:06 -05:00
Owen Schwartz
40a2933e25 Merge pull request #76 from fosrl/bump-version
Bump version
2025-01-17 21:55:34 -05:00
Owen Schwartz
a208ab36b8 Bump version 2025-01-17 21:53:16 -05:00
Milo Schwartz
680c665242 Merge pull request #75 from mallendeo/patch-1
fix: add missing `await` when verifying pincode
2025-01-17 21:26:39 -05:00
Mauricio Allende
6b141c3ea0 fix: add missing await when verifying pincode
`validPincode` ends up as a `Promise` and evaluates as a thruthy value wether the pin is correct or not.
2025-01-17 22:54:20 -03:00
2 changed files with 3 additions and 6 deletions

View File

@@ -18,7 +18,7 @@ import (
) )
func loadVersions(config *Config) { func loadVersions(config *Config) {
config.PangolinVersion = "1.0.0-beta.6" config.PangolinVersion = "1.0.0-beta.7"
config.GerbilVersion = "1.0.0-beta.2" config.GerbilVersion = "1.0.0-beta.2"
} }

View File

@@ -109,15 +109,12 @@ export async function authWithPincode(
return next( return next(
createHttpError( createHttpError(
HttpCode.UNAUTHORIZED, HttpCode.UNAUTHORIZED,
createHttpError( "Resource has no pincode protection"
HttpCode.BAD_REQUEST,
"Resource has no pincode protection"
)
) )
); );
} }
const validPincode = verifyPassword( const validPincode = await verifyPassword(
pincode, pincode,
definedPincode.pincodeHash definedPincode.pincodeHash
); );