aboutsummaryrefslogtreecommitdiff
path: root/packages
diff options
context:
space:
mode:
authorFlorian Dold <florian@dold.me>2021-08-12 19:20:32 +0200
committerFlorian Dold <florian@dold.me>2021-08-12 19:20:48 +0200
commitdf7767697798e1c2d9d1c8c777577adea7f4b342 (patch)
treebfeb8ff69f54225f7dd80239255be322d7859ae5 /packages
parentabbf899b97ed09f215455be3cab8501b5da92860 (diff)
convert performance.now to integer before converting to BigInt
Diffstat (limited to 'packages')
-rw-r--r--packages/taler-wallet-core/src/util/timer.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/packages/taler-wallet-core/src/util/timer.ts b/packages/taler-wallet-core/src/util/timer.ts
index 7c849fbcc..d9fe3439b 100644
--- a/packages/taler-wallet-core/src/util/timer.ts
+++ b/packages/taler-wallet-core/src/util/timer.ts
@@ -91,7 +91,7 @@ export const performanceNow: () => bigint = (() => {
// @ts-ignore
if (typeof performance !== "undefined") {
// @ts-ignore
- return () => BigInt(performance.now()) * BigInt(1000 * 1000);
+ return () => BigInt(Math.floor(performance.now() * 1000)) * BigInt(1000);
}
return () => BigInt(0);