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 changed files with 1 additions and 0 deletions

1
api.go
View File

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