ApiError missing .code in type for haveibeenpwned?
So I installed the HaveIBeenPwned plugin which works, but when handling the error which sets code to it seems that ApiError type doesn't have the code property so i get a typescript error (but my code works). Am I missing something here or is this just a bug?
1 Reply
I tried error.value.body?.code but body is undefined
would it not make sense if instead of ApiError.code it was under ApiError.status like the PASSWORD_TOO_SHORT and PASSWORD_TOO_LONG statuses?