Skip to content

Commit b9282bb

Browse files
committed
Remove checks which are always true
1 parent 46eab1e commit b9282bb

3 files changed

Lines changed: 3 additions & 3 deletions

File tree

extractor/src/main/java/org/schabi/newpipe/extractor/services/peertube/extractors/PeertubeAccountExtractor.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ public void onFetchPage(@Nonnull final Downloader downloader)
163163
}
164164

165165
final Response response = downloader.get(accountUrl);
166-
if (response != null && response.responseBody() != null) {
166+
if (response != null) {
167167
setInitialData(response.responseBody());
168168
} else {
169169
throw new ExtractionException("Unable to extract PeerTube account data");

extractor/src/main/java/org/schabi/newpipe/extractor/services/peertube/extractors/PeertubeChannelExtractor.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ public InfoItemsPage<StreamInfoItem> getPage(final Page page) throws IOException
136136
public void onFetchPage(final Downloader downloader) throws IOException, ExtractionException {
137137
final Response response = downloader.get(
138138
baseUrl + PeertubeChannelLinkHandlerFactory.API_ENDPOINT + getId());
139-
if (response != null && response.responseBody() != null) {
139+
if (response != null ) {
140140
setInitialData(response.responseBody());
141141
} else {
142142
throw new ExtractionException("Unable to extract PeerTube channel data");

extractor/src/main/java/org/schabi/newpipe/extractor/services/peertube/extractors/PeertubeStreamExtractor.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ public String getErrorMessage() {
364364
@Override
365365
public void onFetchPage(final Downloader downloader) throws IOException, ExtractionException {
366366
final Response response = downloader.get(baseUrl + PeertubeStreamLinkHandlerFactory.VIDEO_API_ENDPOINT + getId());
367-
if (response != null && response.responseBody() != null) {
367+
if (response != null) {
368368
setInitialData(response.responseBody());
369369
} else {
370370
throw new ExtractionException("Unable to extract PeerTube channel data");

0 commit comments

Comments
 (0)