Fix: potential out of bounds exception
This commit is contained in:
1 parent
cd475202a9
commit
fcb9062b47
1 file changed
+2
@@ -176,6 +176,8 @@
|
||||
|
||||
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
|
||||
{
|
||||
if (indexPath.row < 0) return nil;
|
||||
|
||||
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"cell"];
|
||||
if (cell == nil) {
|
||||
cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"cell"];
|
||||
|
||||
Reference in new issue
Block a user