summaryrefslogtreecommitdiff
path: root/Juick
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2019-03-25 16:26:48 +0300
committerGravatar Vitaly Takmazov2019-03-25 16:26:48 +0300
commitb45fc82b3413fca41ea3f2029669dc1c3d1ba78f (patch)
treeacba6dc90efe1a1437f4559d3ec5761755bbf6e2 /Juick
parent40e3648eb3b8c6657fddb447e878a551633cd98e (diff)
Fix coalescing
Diffstat (limited to 'Juick')
-rw-r--r--Juick/ViewControllers/MessagesViewController.m2
1 files changed, 1 insertions, 1 deletions
diff --git a/Juick/ViewControllers/MessagesViewController.m b/Juick/ViewControllers/MessagesViewController.m
index 09e84ec..5d47d01 100644
--- a/Juick/ViewControllers/MessagesViewController.m
+++ b/Juick/ViewControllers/MessagesViewController.m
@@ -70,7 +70,7 @@ NSString* const messageCellIdentifier = @"messageCell";
[self.tableView endUpdates];
[self.refreshControl endRefreshing];
if (self.shouldScrollToUnreadOnRefresh) {
- NSInteger itemToScroll = [self.firstUnread integerValue] || self.messages.count - 1;
+ NSInteger itemToScroll = [self.firstUnread integerValue] ? : self.messages.count - 1;
NSIndexPath *lastRow = [NSIndexPath indexPathForRow:itemToScroll inSection:0];
[self.tableView scrollToRowAtIndexPath:lastRow atScrollPosition:UITableViewScrollPositionBottom animated:NO];
self.firstUnread = nil;