diff --git a/Signal/src/ViewControllers/SignalsViewController.m b/Signal/src/ViewControllers/SignalsViewController.m index 24c87229c..5b271e001 100644 --- a/Signal/src/ViewControllers/SignalsViewController.m +++ b/Signal/src/ViewControllers/SignalsViewController.m @@ -26,6 +26,7 @@ #import #import #import +#import #import #import @@ -728,8 +729,8 @@ typedef NS_ENUM(NSInteger, CellState) { kArchiveState, kInboxState }; keyboardOnViewAppearing:(BOOL)keyboardOnViewAppearing callOnViewAppearing:(BOOL)callOnViewAppearing { - // TODO: Do this synchronously if we're already on the main thread. - dispatch_async(dispatch_get_main_queue(), ^{ + // We do this synchronously if we're already on the main thread. + DispatchMainThreadSafe(^{ MessagesViewController *mvc = [[MessagesViewController alloc] initWithNibName:@"MessagesViewController" bundle:nil]; [mvc configureForThread:thread