Merge branch 'mkirk/fix-contact-offer'

pull/1/head
Michael Kirk 8 years ago
commit cc0c914ad1

@ -15,8 +15,6 @@ NS_ASSUME_NONNULL_BEGIN
@interface OWSContactOffersCell ()
@property (nonatomic, nullable) OWSContactOffersInteraction *interaction;
@property (nonatomic) UILabel *titleLabel;
@property (nonatomic) UIButton *addToContactsButton;
@property (nonatomic) UIButton *addToProfileWhitelistButton;
@ -195,15 +193,19 @@ NS_ASSUME_NONNULL_BEGIN
return result;
}
- (void)prepareForReuse
{
[super prepareForReuse];
#pragma mark - Events
self.interaction = nil;
- (nullable OWSContactOffersInteraction *)interaction
{
OWSAssert(self.viewItem);
OWSAssert(self.viewItem.interaction);
if (![self.viewItem.interaction isKindOfClass:[OWSContactOffersInteraction class]]) {
OWSFail(@"%@ expected OWSContactOffersInteraction but found: %@", self.logTag, self.viewItem.interaction);
return nil;
}
return (OWSContactOffersInteraction *)self.viewItem.interaction;
}
#pragma mark - Events
- (void)addToContacts
{
OWSAssert(self.delegate);

Loading…
Cancel
Save