mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2026-01-06 13:12:49 +00:00
[ASDKgram Example] fix crash on startup (#566)
* fix crash on ASDKgram startup * quicker fix
This commit is contained in:
@@ -59,7 +59,7 @@
|
||||
|
||||
[_activityIndicatorView stopAnimating];
|
||||
|
||||
[self insertNewRows:newPhotos];
|
||||
[self.tableView reloadData];
|
||||
[self requestCommentsForPhotos:newPhotos];
|
||||
|
||||
// immediately start second larger fetch
|
||||
@@ -74,7 +74,8 @@
|
||||
NSMutableArray *indexPaths = [NSMutableArray array];
|
||||
|
||||
NSInteger newTotalNumberOfPhotos = [_photoFeed numberOfItemsInFeed];
|
||||
for (NSInteger row = newTotalNumberOfPhotos - newPhotos.count; row < newTotalNumberOfPhotos; row++) {
|
||||
NSInteger existingNumberOfPhotos = newTotalNumberOfPhotos - newPhotos.count;
|
||||
for (NSInteger row = existingNumberOfPhotos; row < newTotalNumberOfPhotos; row++) {
|
||||
NSIndexPath *path = [NSIndexPath indexPathForRow:row inSection:section];
|
||||
[indexPaths addObject:path];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user