mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-24 07:05:35 +00:00
Fix crash if batch update blocks are nil although method declaration allows nullable (#2599)
This commit is contained in:
committed by
Adlai Holler
parent
ae11fc755e
commit
44aa582ceb
@@ -705,6 +705,15 @@
|
||||
}
|
||||
}
|
||||
|
||||
- (void)testThatNilBatchUpdatesCanBeSubmitted
|
||||
{
|
||||
ASTableNode *node = [[ASTableNode alloc] initWithStyle:UITableViewStylePlain];
|
||||
|
||||
// Passing nil blocks should not crash
|
||||
[node performBatchUpdates:nil completion:nil];
|
||||
[node performBatchAnimated:NO updates:nil completion:nil];
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
@implementation UITableView (Testing)
|
||||
|
||||
Reference in New Issue
Block a user