Pass expanded folly::dynamic as argument to sync nativeHook

Reviewed By: mhorowitz

Differential Revision: D4409865

fbshipit-source-id: f99e02e36bf691fa5b4a5affce1fa4fd4cf321a6
This commit is contained in:
Pieter De Baets
2017-01-30 06:39:51 -08:00
committed by Facebook Github Bot
parent 2a638c2ee7
commit 919e49a8b8
3 changed files with 8 additions and 21 deletions

View File

@@ -163,10 +163,6 @@ class NewJavaNativeModule : public NativeModule {
std::vector<MethodDescriptor> methodDescriptors_;
MethodCallResult invokeInner(ExecutorToken token, unsigned int reactMethodId, folly::dynamic&& params) {
if (!params.isArray()) {
throw std::invalid_argument(
folly::to<std::string>("method parameters should be array, but are ", params.typeName()));
}
return methods_[reactMethodId].invoke(instance_, module_.get(), token, params);
}
};