Skip to content
This repository was archived by the owner on Jan 21, 2024. It is now read-only.

Commit 7cbe84d

Browse files
fixed download issue and updated version string
1 parent 695970e commit 7cbe84d

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ android {
1818
minSdkVersion 19
1919
targetSdkVersion 29
2020
versionCode 975
21-
versionName "0.21.9"
21+
versionName "0.21.9_r2"
2222

2323
multiDexEnabled true
2424

app/src/main/java/org/schabi/newpipe/fragments/detail/VideoDetailFragment.java

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@
9191
import org.schabi.newpipe.util.DeviceUtils;
9292
import org.schabi.newpipe.util.ExtractorHelper;
9393
import org.schabi.newpipe.util.ImageDisplayConstants;
94+
import org.schabi.newpipe.util.VideoSegment;
9495
import org.schabi.newpipe.util.external_communication.KoreUtils;
9596
import org.schabi.newpipe.util.ListHelper;
9697
import org.schabi.newpipe.util.Localization;
@@ -1623,12 +1624,18 @@ public void openDownloadDialog() {
16231624
}
16241625

16251626
videoSegmentsSubscriber = Single.fromCallable(() -> {
1627+
VideoSegment[] videoSegments = null;
1628+
16261629
try {
1627-
return SponsorBlockUtils.getYouTubeVideoSegments(getContext(), currentInfo);
1630+
videoSegments =
1631+
SponsorBlockUtils.getYouTubeVideoSegments(getContext(), currentInfo);
16281632
} catch (final Exception e) {
1629-
// TODO: handle
1630-
return null;
1633+
// TODO: handle?
16311634
}
1635+
1636+
return videoSegments == null
1637+
? new VideoSegment[0]
1638+
: videoSegments;
16321639
})
16331640
.subscribeOn(Schedulers.io())
16341641
.observeOn(AndroidSchedulers.mainThread())

0 commit comments

Comments
 (0)