replaces deprecated api usage for android (#62515)

This commit is contained in:
Ayush Bherwani
2020-07-30 10:06:04 +05:30
committed by GitHub
parent 26f9d734e9
commit 87ee003f0c
2 changed files with 5 additions and 5 deletions

View File

@@ -19,7 +19,7 @@ public class {{pluginClass}} implements FlutterPlugin, MethodCallHandler {
@Override
public void onAttachedToEngine(@NonNull FlutterPluginBinding flutterPluginBinding) {
channel = new MethodChannel(flutterPluginBinding.getFlutterEngine().getDartExecutor(), "{{projectName}}");
channel = new MethodChannel(flutterPluginBinding.getBinaryMessenger(), "{{projectName}}");
channel.setMethodCallHandler(this);
}