v1.3 Fix of Google Authenticator migration support #9

Merged
Lisoveliy merged 5 commits from dev into main 2025-07-24 03:18:36 +02:00
Showing only changes of commit 6d15fe9b72 - Show all commits

View File

@ -1,5 +1,5 @@
export function decodeVarint(buffer, offset) { export function decodeVarint(buffer, offset) {
let res = this.BigInt(0); let res = 0;
let shift = 0; let shift = 0;
let byte = 0; let byte = 0;
@ -10,8 +10,8 @@ export function decodeVarint(buffer, offset) {
byte = buffer[offset++]; byte = buffer[offset++];
const multiplier = this.BigInt(2) ** this.BigInt(shift); const multiplier = 2 ** shift;
const thisByteValue = this.BigInt(byte & 0x7f) * multiplier; const thisByteValue = (byte & 0x7f) * multiplier;
shift += 7; shift += 7;
res = res + thisByteValue; res = res + thisByteValue;
} while (byte >= 0x80); } while (byte >= 0x80);