Fix case of adapter being null

Signed-off-by: Mario Danic <mario@lovelyhq.com>
This commit is contained in:
Mario Danic 2019-01-02 00:50:26 +01:00
parent 47bc1e8bbc
commit fb15d625ae

View File

@ -901,7 +901,7 @@ public class ChatController extends BaseController implements MessagesListAdapte
} }
boolean shouldScroll = layoutManager.findFirstVisibleItemPosition() == 0 || boolean shouldScroll = layoutManager.findFirstVisibleItemPosition() == 0 ||
adapter.getItemCount() == 0; (adapter != null && adapter.getItemCount() == 0);
if (!shouldScroll && popupBubble != null) { if (!shouldScroll && popupBubble != null) {
if (!popupBubble.isShown()) { if (!popupBubble.isShown()) {