Commit 972e48c7 authored by Felix Paul Kühne's avatar Felix Paul Kühne

Fix runtime exception

parent f5c568bc
......@@ -105,12 +105,15 @@
if (cell == nil)
cell = [VLCCloudStorageTableViewCell cellWithReuseIdentifier:CellIdentifier];
cell.driveFile = _googleDriveController.currentListFiles[indexPath.row];
if ([cell.driveFile.mimeType isEqualToString:@"application/vnd.google-apps.folder"])
[cell setIsDownloadable:NO];
else
[cell setIsDownloadable:YES];
NSArray *listOfFiles = _googleDriveController.currentListFiles;
NSInteger row = indexPath.row;
if (row < listOfFiles.count) {
cell.driveFile = listOfFiles[row];
if ([cell.driveFile.mimeType isEqualToString:@"application/vnd.google-apps.folder"])
[cell setIsDownloadable:NO];
else
[cell setIsDownloadable:YES];
}
cell.delegate = self;
return cell;
......
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