From 72f7664c709ce2e2bb383ec4559cdf2703d7592a Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Tue, 13 Jul 2021 14:13:38 +0200 Subject: [PATCH] comment --- packages/taler-wallet-core/src/crypto/talerCrypto.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/packages/taler-wallet-core/src/crypto/talerCrypto.ts b/packages/taler-wallet-core/src/crypto/talerCrypto.ts index 7e08d2051..71a804f98 100644 --- a/packages/taler-wallet-core/src/crypto/talerCrypto.ts +++ b/packages/taler-wallet-core/src/crypto/talerCrypto.ts @@ -194,6 +194,12 @@ function kdfMod( } } +// Newer versions of node have TextEncoder and TextDecoder as a global, +// just like modern browsers. +// In older versions of node or environments that do not have these +// globals, they must be polyfilled (by adding them to globa/globalThis) +// before stringToBytes or bytesToString is called the first time. + let encoder: any; let decoder: any;