Skip to content

Commit 73e3288

Browse files
devlearnerStypox
authored andcommitted
Don't finish() to allow recreate
when orientation change is on foot
1 parent 400ee80 commit 73e3288

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

app/src/main/java/org/schabi/newpipe/RouterActivity.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,14 @@ protected void onDestroy() {
161161
disposables.clear();
162162
}
163163

164+
@Override
165+
public void finish() {
166+
// allow the activity to recreate in case orientation changes
167+
if (!isChangingConfigurations()) {
168+
super.finish();
169+
}
170+
}
171+
164172
private void handleUrl(final String url) {
165173
disposables.add(Observable
166174
.fromCallable(() -> {

0 commit comments

Comments
 (0)