mirror of
https://github.com/zadam/trilium.git
synced 2025-11-02 04:29:01 +01:00
fix(routes/api/recovery_codes): convert number into string
fixes type error, as usedStatus is expecting string[] and "indexOf" returns a number
This commit is contained in:
parent
eae68064e5
commit
05917fd815
@ -47,7 +47,7 @@ function getUsedRecoveryCodes() {
|
|||||||
|
|
||||||
recoveryCodes.forEach((recoveryKey: string) => {
|
recoveryCodes.forEach((recoveryKey: string) => {
|
||||||
if (dateRegex.test(recoveryKey)) usedStatus.push(recoveryKey);
|
if (dateRegex.test(recoveryKey)) usedStatus.push(recoveryKey);
|
||||||
else usedStatus.push(recoveryCodes.indexOf(recoveryKey));
|
else usedStatus.push(String(recoveryCodes.indexOf(recoveryKey)));
|
||||||
});
|
});
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user