1
0
mirror of https://github.com/hrfee/jfa-go.git synced 2024-12-22 09:00:10 +00:00

pwr: ensure internal pwr pin is deleted after use

This commit is contained in:
Harvey Tindall 2023-06-22 17:35:34 +01:00
parent 3b3f37365a
commit 4496e1d509
Signed by: hrfee
GPG Key ID: BBC65952848FB1A2

1
api.go
View File

@ -143,6 +143,7 @@ func (app *appContext) ResetSetPassword(gc *gin.Context) {
respondBool(status, false, gc) respondBool(status, false, gc)
return return
} }
delete(app.internalPWRs, req.PIN)
} else { } else {
resp, status, err := app.jf.ResetPassword(req.PIN) resp, status, err := app.jf.ResetPassword(req.PIN)
if status != 200 || err != nil || !resp.Success { if status != 200 || err != nil || !resp.Success {