diff --git a/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java b/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java index 182f31fa1..bad22304b 100644 --- a/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java +++ b/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java @@ -5342,6 +5342,9 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis String isFreeGift = newPeopleTask.getIs_free_gift(); + + Log.i("TestFreeGift", "newPeopleTask.getIs_free_gift(): " + isFreeGift); + if (taskModel != null) { GiftModel giftModel = newPeopleTask.getGift(); if (giftModel != null) { diff --git a/main/src/main/java/com/yunbao/main/activity/LoginActivity.java b/main/src/main/java/com/yunbao/main/activity/LoginActivity.java index f50dff2fa..6352efa82 100644 --- a/main/src/main/java/com/yunbao/main/activity/LoginActivity.java +++ b/main/src/main/java/com/yunbao/main/activity/LoginActivity.java @@ -288,7 +288,13 @@ public class LoginActivity extends AbsActivity { getBaseUserInfo(); } else { ToastUtil.show(msg); - loadingDialog.dismiss(); + try { + if(loadingDialog!=null && loadingDialog.isAdded()){ + loadingDialog.dismiss(); + } + }catch (Exception e){ + e.printStackTrace(); + } } } @@ -321,11 +327,14 @@ public class LoginActivity extends AbsActivity { } else { MainActivity.forward(LoginActivity.this, false); } - if(loadingDialog!=null){ - loadingDialog.dismiss(); + try { + if(loadingDialog!=null && loadingDialog.isAdded()){ + loadingDialog.dismiss(); + } + }catch (Exception e){ + e.printStackTrace(); } finish(); - } @Override