diff --git a/multilibrary/src/main/java/com/zhongjh/albumcamerarecorder/MainActivity.java b/multilibrary/src/main/java/com/zhongjh/albumcamerarecorder/MainActivity.java index 3d5cf875..dda226a5 100644 --- a/multilibrary/src/main/java/com/zhongjh/albumcamerarecorder/MainActivity.java +++ b/multilibrary/src/main/java/com/zhongjh/albumcamerarecorder/MainActivity.java @@ -134,8 +134,10 @@ public void finish() { @Override protected void onDestroy() { + if (mLayoutMediator != null) { + mLayoutMediator.detach(); + } super.onDestroy(); - mLayoutMediator.detach(); } @Override