mirror of
https://github.com/revanced/revanced-integrations.git
synced 2024-11-18 18:09:23 +01:00
fix(reddit/hide-ads): only filter promoted links
This commit is contained in:
parent
8d0d5f9659
commit
efc2b9b6a3
@ -13,12 +13,9 @@ public final class FilterPromotedLinksPatch {
|
||||
final List<Object> filteredList = new ArrayList<>();
|
||||
|
||||
for (Object item : links) {
|
||||
if (!(item instanceof ILink)) continue;
|
||||
if (item instanceof ILink && ((ILink) item).getPromoted()) continue;
|
||||
|
||||
final var link = (ILink) item;
|
||||
final var isPromotedAd = link.getPromoted();
|
||||
|
||||
if (!isPromotedAd) filteredList.add(item);
|
||||
filteredList.add(item);
|
||||
}
|
||||
|
||||
return filteredList;
|
||||
|
Loading…
Reference in New Issue
Block a user