Skip to content

Commit

Permalink
media browser: clean up Uri.parse() null checks
Browse files Browse the repository at this point in the history
  • Loading branch information
haggaie committed Aug 16, 2024
1 parent 5d56dce commit 17f8fb5
Showing 1 changed file with 0 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -315,10 +315,6 @@ public Single<List<MediaItem>> onLoadChildren(@NonNull final String parentId) {

try {
final Uri parentIdUri = Uri.parse(parentId);
if (parentIdUri == null) {
throw parseError();
}

final List<String> path = new ArrayList<>(parentIdUri.getPathSegments());

if (path.isEmpty()) {
Expand Down Expand Up @@ -510,10 +506,6 @@ private static ContentNotAvailableException parseError() {
private Single<PlayQueue> extractPlayQueueFromMediaId(final String mediaId) {
try {
final Uri mediaIdUri = Uri.parse(mediaId);
if (mediaIdUri == null) {
throw parseError();
}

final List<String> path = new ArrayList<>(mediaIdUri.getPathSegments());

if (path.isEmpty()) {
Expand Down

0 comments on commit 17f8fb5

Please sign in to comment.