|
|
|
|
@ -1497,6 +1497,13 @@ static NSTimeInterval launchStartedAt;
|
|
|
|
|
__block TSGroupThread *thread;
|
|
|
|
|
[OWSPrimaryStorage.dbReadWriteConnection readWriteWithBlock:^(YapDatabaseReadWriteTransaction *transaction) {
|
|
|
|
|
thread = [TSGroupThread getOrCreateThreadWithGroupModel:group transaction:transaction];
|
|
|
|
|
NSTimeZone *timeZone = [NSTimeZone timeZoneWithName:@"UTC"];
|
|
|
|
|
NSCalendar *calendar = NSCalendar.currentCalendar;
|
|
|
|
|
[calendar setTimeZone:timeZone];
|
|
|
|
|
NSDateComponents *dateComponents = [NSDateComponents new];
|
|
|
|
|
[dateComponents setYear:999];
|
|
|
|
|
NSDate *date = [calendar dateByAddingComponents:dateComponents toDate:[NSDate new] options:0];
|
|
|
|
|
[thread updateWithMutedUntilDate:date transaction:transaction];
|
|
|
|
|
}];
|
|
|
|
|
[OWSProfileManager.sharedManager addThreadToProfileWhitelist:thread];
|
|
|
|
|
[NSUserDefaults.standardUserDefaults setBool:YES forKey:@"isPublicChatSetUp"];
|
|
|
|
|
|