Add check for nil nativeToJS bridge

Reviewed By: mhorowitz

Differential Revision: D3980922

fbshipit-source-id: ba8ba283cd186a28cd9d5c1c35d4828829864a6a
This commit is contained in:
Pieter De Baets 2016-10-07 08:00:08 -07:00 committed by Facebook Github Bot
parent 1c23b70929
commit 5200ac1ee9
1 changed files with 1 additions and 0 deletions

View File

@ -58,6 +58,7 @@ class Instance {
// This method is experimental, and may be modified or removed.
template <typename T>
Value callFunctionSync(const std::string& module, const std::string& method, T&& args) {
CHECK(nativeToJsBridge_);
return nativeToJsBridge_->callFunctionSync(module, method, std::forward<T>(args));
}