Protect against action bar

Signed-off-by: Mario Danic <mario@lovelyhq.com>
This commit is contained in:
Mario Danic 2018-01-21 08:29:14 +01:00
parent 08f959c060
commit cb55e32355
3 changed files with 10 additions and 3 deletions

View file

@ -130,7 +130,9 @@ public class CallsListController extends BaseController implements SearchView.On
super.onViewBound(view);
NextcloudTalkApplication.getSharedApplication().getComponentApplication().inject(this);
getActionBar().show();
if (getActionBar() != null) {
getActionBar().show();
}
userEntity = userUtils.getCurrentUser();

View file

@ -234,7 +234,10 @@ public class SettingsController extends BaseController {
@Override
protected void onAttach(@NonNull View view) {
super.onAttach(view);
getActionBar().show();
if (getActionBar() != null) {
getActionBar().show();
}
dispose(null);
userEntity = userUtils.getCurrentUser();

View file

@ -179,7 +179,9 @@ public class SwitchAccountController extends BaseController {
adapter.addListener(onSwitchItemClickListener);
adapter.updateDataSet(userItems, false);
} else {
getActionBar().show();
if (getActionBar() != null) {
getActionBar().show();
}
Account account;
ImportAccount importAccount;
for (Object accountObject : AccountUtils.findAccounts(userUtils.getUsers())) {