mirror of
https://github.com/tbnobody/OpenDTU.git
synced 2025-12-10 16:59:52 +01:00
webapp: Make compiler happy
This commit is contained in:
@@ -105,9 +105,12 @@ export default defineComponent({
|
||||
let sn_int: bigint = 0n;
|
||||
|
||||
for (let i = 0; i < 9; i++) {
|
||||
const pos: bigint = BigInt(chars32.indexOf(sn[i].toUpperCase()));
|
||||
const shift: bigint = BigInt(42 - 5 * i - (i <= 2 ? 0 : 2));
|
||||
sn_int |= pos << shift;
|
||||
const c = sn[i];
|
||||
if (typeof c === 'string') {
|
||||
const pos: bigint = BigInt(chars32.indexOf(c.toUpperCase()));
|
||||
const shift: bigint = BigInt(42 - 5 * i - (i <= 2 ? 0 : 2));
|
||||
sn_int |= pos << shift;
|
||||
}
|
||||
}
|
||||
|
||||
return sn_int.toString(16);
|
||||
|
||||
Reference in New Issue
Block a user