From 8565cd7d4074c145dd7d6d62ee2317c8eac7d2e0 Mon Sep 17 00:00:00 2001 From: Laurent Cozic Date: Fri, 27 Sep 2019 22:18:22 +0100 Subject: [PATCH] Cli: Resolves #1905: Add support to Termux by returning a default when platform name cannot be determined --- ReactNativeClient/lib/shim.js | 1 + 1 file changed, 1 insertion(+) diff --git a/ReactNativeClient/lib/shim.js b/ReactNativeClient/lib/shim.js index f39bcb31e..44ae2c8d6 100644 --- a/ReactNativeClient/lib/shim.js +++ b/ReactNativeClient/lib/shim.js @@ -38,6 +38,7 @@ shim.platformName = function() { if (shim.isWindows()) return 'win32'; if (shim.isLinux()) return 'linux'; if (shim.isFreeBSD()) return 'freebsd'; + if (process && process.platform) return process.platform; throw new Error('Cannot determine platform'); };