Add protocol context to protocol kit.

pull/1/head
Matthew Chen 7 years ago
parent bbd689bfd0
commit c8e7eb903c

@ -578,7 +578,6 @@ NSString *const kNSNotificationName_IdentityStateDidChange = @"kNSNotificationNa
{
OWSAssert(message);
OWSAssert(message.verificationForRecipientId.length > 0);
OWSAssertIsOnMainThread();
TSContactThread *contactThread = [TSContactThread getOrCreateThreadWithContactId:message.verificationForRecipientId];

@ -128,6 +128,8 @@ OWSSignalServiceProtosVerifiedState OWSVerificationStateToProtoState(OWSVerifica
- (void)saveWithTransaction:(YapDatabaseReadWriteTransaction *)transaction
{
// For consistency, we should only access instances of this class on
// non-caching connections.
OWSAssert(!transaction.connection.objectCacheEnabled);
[super saveWithTransaction:transaction];
@ -135,6 +137,8 @@ OWSSignalServiceProtosVerifiedState OWSVerificationStateToProtoState(OWSVerifica
- (void)removeWithTransaction:(YapDatabaseReadWriteTransaction *)transaction
{
// For consistency, we should only access instances of this class on
// non-caching connections.
OWSAssert(!transaction.connection.objectCacheEnabled);
[super removeWithTransaction:transaction];
@ -142,6 +146,8 @@ OWSSignalServiceProtosVerifiedState OWSVerificationStateToProtoState(OWSVerifica
- (void)touchWithTransaction:(YapDatabaseReadWriteTransaction *)transaction
{
// For consistency, we should only access instances of this class on
// non-caching connections.
OWSAssert(!transaction.connection.objectCacheEnabled);
[super touchWithTransaction:transaction];
@ -150,6 +156,8 @@ OWSSignalServiceProtosVerifiedState OWSVerificationStateToProtoState(OWSVerifica
+ (nullable instancetype)fetchObjectWithUniqueID:(NSString *)uniqueID
transaction:(YapDatabaseReadTransaction *)transaction
{
// For consistency, we should only access instances of this class on
// non-caching connections.
OWSAssert(!transaction.connection.objectCacheEnabled);
return [super fetchObjectWithUniqueID:uniqueID transaction:transaction];

Loading…
Cancel
Save