Skip to content

Commit

Permalink
Use weak reference to avoid a retain cycle
Browse files Browse the repository at this point in the history
  • Loading branch information
crazytonyli committed Jul 10, 2023
1 parent db15a47 commit 7dbb2e5
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1123,7 +1123,7 @@ - (void)configureCell:(UITableViewCell *)aCell atIndexPath:(NSIndexPath *)indexP

cell.accessoryButtonAction = ^(UIView * _Nonnull sourceView) {
if (comment) {
[self shareComment:comment sourceView:sourceView];
[weakSelf shareComment:comment sourceView:sourceView];
}
};

Expand Down

0 comments on commit 7dbb2e5

Please sign in to comment.