Commit dac4d8dc authored by Felix Paul Kühne's avatar Felix Paul Kühne

Fix runtime exception

(cherry picked from commit 3faa83ce)
parent f7e87ee1
......@@ -138,9 +138,12 @@
BOOL isSelected = player.currentChapterIndex == row;
trackCell.selectionMarkerVisible = isSelected;
NSDictionary *description = [player chapterDescriptionsOfTitle:player.currentTitleIndex][row];
NSArray *chapterDescriptions = [player chapterDescriptionsOfTitle:player.currentTitleIndex];
if (row < chapterDescriptions.count) {
NSDictionary *description = chapterDescriptions[row];
NSString *chapterTitle = [NSString stringWithFormat:@"%@ (%@)", description[VLCChapterDescriptionName], [[VLCTime timeWithNumber:description[VLCChapterDescriptionDuration]] stringValue]];
trackCell.titleLabel.text = chapterTitle;
}
}
-(void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment