Merge branch 'charlesmchen/fixTableAssert'

pull/1/head
Matthew Chen 8 years ago
commit ff6f383469

@ -37,7 +37,7 @@ typedef NS_ENUM(NSInteger, OWSTableItemType) {
}; };
typedef void (^OWSTableActionBlock)(); typedef void (^OWSTableActionBlock)();
typedef UITableViewCell * (^OWSTableCustomCellBlock)(); typedef UITableViewCell *_Nonnull (^OWSTableCustomCellBlock)();
@interface OWSTableItem : NSObject @interface OWSTableItem : NSObject
@ -54,7 +54,7 @@ typedef UITableViewCell * (^OWSTableCustomCellBlock)();
+ (OWSTableItem *)itemWithCustomCellBlock:(OWSTableCustomCellBlock)customCellBlock + (OWSTableItem *)itemWithCustomCellBlock:(OWSTableCustomCellBlock)customCellBlock
actionBlock:(nullable OWSTableActionBlock)actionBlock; actionBlock:(nullable OWSTableActionBlock)actionBlock;
- (UITableViewCell *)customCell; - (nullable UITableViewCell *)customCell;
- (NSNumber *)customRowHeight; - (NSNumber *)customRowHeight;
@end @end

@ -141,7 +141,7 @@ NS_ASSUME_NONNULL_BEGIN
return item; return item;
} }
- (UITableViewCell *)customCell - (nullable UITableViewCell *)customCell
{ {
if (_customCell) { if (_customCell) {
return _customCell; return _customCell;
@ -149,7 +149,6 @@ NS_ASSUME_NONNULL_BEGIN
if (_customCellBlock) { if (_customCellBlock) {
return _customCellBlock(); return _customCellBlock();
} }
OWSAssert(0);
return nil; return nil;
} }

Loading…
Cancel
Save