Skip to content

Commit 06803a2

Browse files
committed
channel groups: crash fix when channelId is null
1 parent df4e87a commit 06803a2

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

common/src/main/java/com/liskovsoft/smartyoutubetv2/common/app/presenters/dialogs/menu/providers/channelgroup/ChannelGroupMenuProvider.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,10 @@ private void showGroupDialogAndFetchChannel(Video item, VideoMenuCallback callba
6666
}
6767

6868
private void showGroupDialog(Video item, VideoMenuCallback callback) {
69+
if (item == null || item.channelId == null) {
70+
return;
71+
}
72+
6973
AppDialogPresenter dialogPresenter = AppDialogPresenter.instance(getContext());
7074

7175
List<ItemGroup> groups = mService.getChannelGroups();
@@ -101,8 +105,6 @@ private void showGroupDialog(Video item, VideoMenuCallback callback) {
101105
});
102106
}, false));
103107

104-
//options.add(AppDialogUtil.createSubscriptionsBackupButton(getContext()));
105-
106108
for (ItemGroup group : groups) {
107109
options.add(UiOptionItem.from(group.getTitle(), optionItem -> {
108110
BrowsePresenter presenter = BrowsePresenter.instance(getContext());

0 commit comments

Comments
 (0)