diff options
author | Martin Fietz <martin.fietz@gmail.com> | 2018-01-14 18:02:56 +0100 |
---|---|---|
committer | Martin Fietz <martin.fietz@gmail.com> | 2018-01-14 18:02:56 +0100 |
commit | e02baebf02d4571d2b0202f0956f1664ab3c0963 (patch) | |
tree | ffc80e2d43d061e4c14e4c03cbce0440d5ca9c05 /app/src | |
parent | d7e1b0f9777bf98e345f258a0af6322f6a1f3e01 (diff) | |
download | AntennaPod-e02baebf02d4571d2b0202f0956f1664ab3c0963.zip |
Use bulk operation instead of iteration
Diffstat (limited to 'app/src')
-rw-r--r-- | app/src/main/java/de/danoeh/antennapod/adapter/NavListAdapter.java | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/NavListAdapter.java b/app/src/main/java/de/danoeh/antennapod/adapter/NavListAdapter.java index 465497b55..cbbeabf0d 100644 --- a/app/src/main/java/de/danoeh/antennapod/adapter/NavListAdapter.java +++ b/app/src/main/java/de/danoeh/antennapod/adapter/NavListAdapter.java @@ -86,9 +86,7 @@ public class NavListAdapter extends BaseAdapter private void loadItems() { List<String> newTags = new ArrayList<>(Arrays.asList(MainActivity.NAV_DRAWER_TAGS)); List<String> hiddenFragments = UserPreferences.getHiddenDrawerItems(); - for(String hidden : hiddenFragments) { - newTags.remove(hidden); - } + newTags.removeAll(hiddenFragments); if (newTags.contains(SUBSCRIPTION_LIST_TAG)) { // we never want SUBSCRIPTION_LIST_TAG to be in 'tags' |