From fdb1ea6213aec62bed83f3ef1418c5a5bc38a0a5 Mon Sep 17 00:00:00 2001 From: Clayton Wilson Date: Sat, 31 Oct 2020 20:47:48 -0400 Subject: [PATCH] Fix branch merge bug --- .../src/main/java/com/example/listify/SearchResults.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/Listify/app/src/main/java/com/example/listify/SearchResults.java b/Listify/app/src/main/java/com/example/listify/SearchResults.java index c9712a0..0421b58 100644 --- a/Listify/app/src/main/java/com/example/listify/SearchResults.java +++ b/Listify/app/src/main/java/com/example/listify/SearchResults.java @@ -277,6 +277,13 @@ public class SearchResults extends AppCompatActivity implements SortDialogFragme }); resultsProductListSorted.clear(); resultsProductListSorted.addAll(temp); + + runOnUiThread(new Runnable() { + @Override + public void run() { + searchResultsListAdapter.notifyDataSetChanged(); + } + }); } // This is called after the search results come back from the server @@ -321,8 +328,6 @@ public class SearchResults extends AppCompatActivity implements SortDialogFragme runOnUiThread(new Runnable() { @Override public void run() { - searchResultsListAdapter.notifyDataSetChanged(); - // Hide progress bar loadingSearch.setVisibility(View.GONE);