diff --git a/app/src/main/java/org/schabi/newpipe/local/playlist/LocalPlaylistFragment.java b/app/src/main/java/org/schabi/newpipe/local/playlist/LocalPlaylistFragment.java index edfdc022f..0881c6b97 100644 --- a/app/src/main/java/org/schabi/newpipe/local/playlist/LocalPlaylistFragment.java +++ b/app/src/main/java/org/schabi/newpipe/local/playlist/LocalPlaylistFragment.java @@ -79,7 +79,7 @@ public class LocalPlaylistFragment extends BaseLocalListFragment playlist) -> { HistoryRecordManager recordManager = new HistoryRecordManager(getContext()); @@ -382,19 +387,22 @@ public class LocalPlaylistFragment extends BaseLocalListFragment historyStreamIds = new ArrayList<>(); - while(historyIter.hasNext()) { + while (historyIter.hasNext()) { historyStreamIds.add(historyIter.next().getStreamId()); } List notWatchedItems = new ArrayList<>(); boolean thumbnailVideoRemoved = false; - while(playlistIter.hasNext()) { + while (playlistIter.hasNext()) { PlaylistStreamEntry playlistItem = playlistIter.next(); - int indexInHistory = Collections.binarySearch(historyStreamIds, playlistItem.getStreamId()); + int indexInHistory = Collections.binarySearch(historyStreamIds, + playlistItem.getStreamId()); if (indexInHistory < 0) { notWatchedItems.add(playlistItem); - } else if (!thumbnailVideoRemoved && playlistManager.getPlaylistThumbnail(playlistId).equals(playlistItem.getStreamEntity().getThumbnailUrl())) { + } else if (!thumbnailVideoRemoved + && playlistManager.getPlaylistThumbnail(playlistId) + .equals(playlistItem.getStreamEntity().getThumbnailUrl())) { thumbnailVideoRemoved = true; } } @@ -403,7 +411,8 @@ public class LocalPlaylistFragment extends BaseLocalListFragment { - List notWatchedItems = (List) flow.blockingFirst(); + List notWatchedItems = + (List) flow.blockingFirst(); boolean thumbnailVideoRemoved = (Boolean) flow.blockingLast(); itemListAdapter.clearStreamItemList();