From 34cbaa8dcdc09c46bf2db2ff407f4e9a29f57adf Mon Sep 17 00:00:00 2001 From: Ryan Lester Date: Sat, 29 Sep 2018 18:22:42 -0400 Subject: [PATCH] useBackupModule getRandomValue fix --- dist-build/emscripten.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/dist-build/emscripten.sh b/dist-build/emscripten.sh index 8a7c950f..8139ba07 100755 --- a/dist-build/emscripten.sh +++ b/dist-build/emscripten.sh @@ -110,7 +110,9 @@ if [ "$DIST" = yes ]; then Module.useBackupModule = function() { var Module = _Module; Object.keys(Module).forEach(function(k) { - delete Module[k]; + if (k !== 'getRandomValue') { + delete Module[k]; + } }); $(cat "${PREFIX}/lib/libsodium.asm.tmp.js" | sed 's|use asm||g') };