fixed NPE in channel discovery after race to create menu

This commit is contained in:
Daniel Gultsch 2019-05-22 17:29:27 +02:00
parent 1db07b84f3
commit a909e1a7cf
1 changed files with 1 additions and 1 deletions

View File

@ -94,7 +94,7 @@ public class ChannelDiscoveryActivity extends XmppActivity implements MenuItem.O
mMenuSearchView.expandActionView(); mMenuSearchView.expandActionView();
mSearchEditText.append(initialSearchValue); mSearchEditText.append(initialSearchValue);
mSearchEditText.requestFocus(); mSearchEditText.requestFocus();
if (optedIn) { if (optedIn && xmppConnectionService != null) {
xmppConnectionService.discoverChannels(initialSearchValue, this); xmppConnectionService.discoverChannels(initialSearchValue, this);
} }
} }