Skip to content

Commit 3c8b3ab

Browse files
Catch HttpResponseException in to fix SoundcloudChartsExtractorTest.testRelatedItems and testMoreRelatedItems
1 parent a437a5d commit 3c8b3ab

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

extractor/src/main/java/org/schabi/newpipe/extractor/services/soundcloud/extractors/SoundcloudChartsExtractor.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
import org.schabi.newpipe.extractor.StreamingService;
99
import org.schabi.newpipe.extractor.downloader.Downloader;
1010
import org.schabi.newpipe.extractor.exceptions.ExtractionException;
11+
import org.schabi.newpipe.extractor.exceptions.HttpResponseException;
1112
import org.schabi.newpipe.extractor.kiosk.KioskExtractor;
1213
import org.schabi.newpipe.extractor.linkhandler.ListLinkHandler;
1314
import org.schabi.newpipe.extractor.localization.ContentCountry;
@@ -56,7 +57,7 @@ public void onFetchPage(@Nonnull final Downloader downloader)
5657
initialFetchNextPageUrl = SoundcloudParsingHelper.getStreamsFromApi(
5758
initialFetchCollector,
5859
apiUrlWithRegion == null ? apiUrl : apiUrlWithRegion, true);
59-
} catch (final IOException e) {
60+
} catch (final IOException | HttpResponseException e) {
6061
// Request to other region may be geo-restricted.
6162
// See https://github.com/TeamNewPipe/NewPipeExtractor/issues/537.
6263
// We retry without the specified region.

0 commit comments

Comments
 (0)