Remove capture of instance_

Summary:
The captured `instance_` will result in a call to JVM code to release the reference when the lambda is destroyed. However, Hermes may destroy the lambda in a non-JVM background thread.

Since `instance_` is a member of the class, and `this` is already captured, there is no need to capture it.

Changelog: [Internal]

Reviewed By: RSNara

Differential Revision: D24141179

fbshipit-source-id: e3b268485ed229ee933281a80e5dbe2feba55719
This commit is contained in:
Neil Dhar
2020-10-06 17:33:05 -07:00
committed by Facebook GitHub Bot
parent 88174991d9
commit dffb61dcbb
@@ -733,7 +733,6 @@ jsi::Value JavaTurboModule::invokeJavaMethod(
&jargs,
&globalRefs,
argCount,
instance_ = instance_,
methodID,
moduleNameStr = name_,
methodNameStr,