summaryrefslogtreecommitdiff
path: root/storage/database
diff options
context:
space:
mode:
authorTaco <SkytkRSfan3895@gmail.com>2024-04-05 20:28:36 +0300
committerGitHub <noreply@github.com>2024-04-05 19:28:36 +0200
commitb6a4049ff4a792cbed826320064ccca72fc3e6e5 (patch)
tree83b8b52a1954c2b1374ee5b691c7bd0e00009c71 /storage/database
parent92ab575b150ab49ca85e0ac994558142e49c9e68 (diff)
downloadAntennaPod-b6a4049ff4a792cbed826320064ccca72fc3e6e5.zip
Spotbugs cleanup (#6968)
Remove unused SpotBugs rules. Fix URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD, ICAST_INTEGER_MULTIPLY_CAST_TO_LONG, NP_METHOD_PARAMETER_TIGHTENS_ANNOTATION, OBL_UNSATISFIED_OBLIGATION_EXCEPTION_EDGE
Diffstat (limited to 'storage/database')
-rw-r--r--storage/database/src/main/java/de/danoeh/antennapod/storage/database/DBReader.java2
-rw-r--r--storage/database/src/main/java/de/danoeh/antennapod/storage/database/NavDrawerData.java6
2 files changed, 6 insertions, 2 deletions
diff --git a/storage/database/src/main/java/de/danoeh/antennapod/storage/database/DBReader.java b/storage/database/src/main/java/de/danoeh/antennapod/storage/database/DBReader.java
index 4fdcee987..a6669601e 100644
--- a/storage/database/src/main/java/de/danoeh/antennapod/storage/database/DBReader.java
+++ b/storage/database/src/main/java/de/danoeh/antennapod/storage/database/DBReader.java
@@ -741,7 +741,7 @@ public final class DBReader {
folders.put(tag, folder);
}
drawerItem.id |= folder.id;
- folder.children.add(drawerItem);
+ folder.getChildren().add(drawerItem);
}
}
List<NavDrawerData.TagDrawerItem> foldersSorted = new ArrayList<>(folders.values());
diff --git a/storage/database/src/main/java/de/danoeh/antennapod/storage/database/NavDrawerData.java b/storage/database/src/main/java/de/danoeh/antennapod/storage/database/NavDrawerData.java
index d5856c10a..5be824752 100644
--- a/storage/database/src/main/java/de/danoeh/antennapod/storage/database/NavDrawerData.java
+++ b/storage/database/src/main/java/de/danoeh/antennapod/storage/database/NavDrawerData.java
@@ -53,7 +53,7 @@ public class NavDrawerData {
}
public static class TagDrawerItem extends DrawerItem {
- public final List<DrawerItem> children = new ArrayList<>();
+ private final List<DrawerItem> children = new ArrayList<>();
private final String name;
private boolean isOpen;
@@ -75,6 +75,10 @@ public class NavDrawerData {
isOpen = open;
}
+ public List<DrawerItem> getChildren() {
+ return children;
+ }
+
public int getCounter() {
int sum = 0;
for (DrawerItem item : children) {