mirror of
https://github.com/status-im/react-native.git
synced 2025-01-26 17:30:25 +00:00
Catch any std::exception from unbundling
Reviewed By: davidaurelio Differential Revision: D3148408 fbshipit-source-id: 78dc47e1b092cb7fd06307d505a795d2009cee4d
This commit is contained in:
parent
448b48ca85
commit
05832c3469
@ -489,7 +489,7 @@ JSValueRef JSCExecutor::nativeRequire(
|
||||
if (moduleId <= (double) std::numeric_limits<uint32_t>::max() && moduleId >= 0.0) {
|
||||
try {
|
||||
loadModule(moduleId);
|
||||
} catch (JSModulesUnbundle::ModuleNotFound&) {
|
||||
} catch (const std::exception&) {
|
||||
throw std::invalid_argument(folly::to<std::string>("Received invalid module ID: ", moduleId));
|
||||
}
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user