[SoundCloud] Return empty video stream list instead of null

Also replace every instance of `return new ArrayList<>();` with `return Collections.emptyList();`
This commit is contained in:
Stypox 2020-04-09 18:15:34 +02:00
parent 072bae321f
commit 3b2cfb4ca2
No known key found for this signature in database
GPG key ID: 4BDF1B40A49FDD23
3 changed files with 6 additions and 6 deletions

View file

@ -277,8 +277,8 @@ public class MediaCCCStreamExtractor extends StreamExtractor {
@Nonnull @Nonnull
@Override @Override
public List<String> getTags() { public List<String> getTags() throws ParsingException {
return new ArrayList<>(); return Collections.emptyList();
} }
@Nonnull @Nonnull

View file

@ -235,12 +235,12 @@ public class SoundcloudStreamExtractor extends StreamExtractor {
@Override @Override
public List<VideoStream> getVideoStreams() throws IOException, ExtractionException { public List<VideoStream> getVideoStreams() throws IOException, ExtractionException {
return null; return Collections.emptyList();
} }
@Override @Override
public List<VideoStream> getVideoOnlyStreams() throws IOException, ExtractionException { public List<VideoStream> getVideoOnlyStreams() throws IOException, ExtractionException {
return null; return Collections.emptyList();
} }
@Override @Override
@ -304,7 +304,7 @@ public class SoundcloudStreamExtractor extends StreamExtractor {
@Nonnull @Nonnull
@Override @Override
public List<String> getTags() throws ParsingException { public List<String> getTags() throws ParsingException {
return new ArrayList<>(); return Collections.emptyList();
} }
@Nonnull @Nonnull

View file

@ -1087,7 +1087,7 @@ public class YoutubeStreamExtractor extends StreamExtractor {
@Nonnull @Nonnull
@Override @Override
public List<String> getTags() { public List<String> getTags() {
return new ArrayList<>(); return Collections.emptyList();
} }
@Nonnull @Nonnull