mirror of
https://github.com/bitwarden/clients.git
synced 2026-07-10 21:03:56 +08:00
check that period is positive value
This commit is contained in:
parent
41ab22a82f
commit
ee13a562f9
@ -30,7 +30,10 @@ export class TotpService implements TotpServiceAbstraction {
|
||||
}
|
||||
if (params.has('period') && params.get('period') != null) {
|
||||
try {
|
||||
period = parseInt(params.get('period').trim(), null);
|
||||
const periodParam = parseInt(params.get('period').trim(), null);
|
||||
if (periodParam > 0) {
|
||||
period = periodParam;
|
||||
}
|
||||
} catch { }
|
||||
}
|
||||
if (params.has('secret') && params.get('secret') != null) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user