From 469f41b955305a7ffe53d6e9e46d8aaa55eedee3 Mon Sep 17 00:00:00 2001 From: Moxie Marlinspike Date: Tue, 1 Nov 2016 08:53:54 -0700 Subject: [PATCH] Fix NPE Fixes #5829 // FREEBIE --- src/org/thoughtcrime/securesms/giph/ui/GiphyFragment.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/org/thoughtcrime/securesms/giph/ui/GiphyFragment.java b/src/org/thoughtcrime/securesms/giph/ui/GiphyFragment.java index d90065ced0..b465b43914 100644 --- a/src/org/thoughtcrime/securesms/giph/ui/GiphyFragment.java +++ b/src/org/thoughtcrime/securesms/giph/ui/GiphyFragment.java @@ -66,8 +66,8 @@ public abstract class GiphyFragment extends Fragment implements LoaderManager.Lo public void onLoadFinished(Loader> loader, List data) { this.loadingProgress.setVisibility(View.GONE); - if (data.isEmpty()) noResultsView.setVisibility(View.VISIBLE); - else noResultsView.setVisibility(View.GONE); + if (data == null || data.isEmpty()) noResultsView.setVisibility(View.VISIBLE); + else noResultsView.setVisibility(View.GONE); this.giphyAdapter.setImages(data); }