Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
review fixes
  • Loading branch information
Chris Yang committed Oct 14, 2019
commit c76a83829c4d119dd7a4ab417905a8d49b70692c
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,7 @@ public void onAttachedToActivity(ActivityPluginBinding binding) {

@Override
public void onDetachedFromActivity() {
share.setActivity(null);
methodChannel.setMethodCallHandler(null);
tearDownChannel();
}

@Override
Expand All @@ -63,4 +62,9 @@ private void setUpChannel(BinaryMessenger messenger) {
handler = new MethodCallHandler(share);
methodChannel.setMethodCallHandler(handler);
}

private void tearDownChannel() {
share.setActivity(null);
methodChannel.setMethodCallHandler(null);
}
}