mirror of https://github.com/oxen-io/session-ios
Implement sending side of revocation
parent
936424e344
commit
850346acf2
@ -0,0 +1,8 @@
|
|||||||
|
#import "TSOutgoingMessage.h"
|
||||||
|
|
||||||
|
NS_SWIFT_NAME(UnlinkDeviceMessage)
|
||||||
|
@interface LKUnlinkDeviceMessage : TSOutgoingMessage
|
||||||
|
|
||||||
|
- (instancetype)initWithThread:(TSThread *)thread;
|
||||||
|
|
||||||
|
@end
|
@ -0,0 +1,26 @@
|
|||||||
|
#import "LKUnlinkDeviceMessage.h"
|
||||||
|
#import <SignalCoreKit/NSDate+OWS.h>
|
||||||
|
#import <SignalServiceKit/SignalServiceKit-Swift.h>
|
||||||
|
|
||||||
|
@implementation LKUnlinkDeviceMessage
|
||||||
|
|
||||||
|
#pragma mark Initialization
|
||||||
|
- (instancetype)initWithThread:(TSThread *)thread {
|
||||||
|
return [self initOutgoingMessageWithTimestamp:NSDate.ows_millisecondTimeStamp inThread:thread messageBody:@"" attachmentIds:[NSMutableArray<NSString *> new]
|
||||||
|
expiresInSeconds:0 expireStartedAt:0 isVoiceMessage:NO groupMetaMessage:TSGroupMetaMessageUnspecified quotedMessage:nil contactShare:nil linkPreview:nil];
|
||||||
|
}
|
||||||
|
|
||||||
|
#pragma mark Building
|
||||||
|
- (nullable SSKProtoDataMessageBuilder *)dataMessageBuilder
|
||||||
|
{
|
||||||
|
SSKProtoDataMessageBuilder *builder = super.dataMessageBuilder;
|
||||||
|
if (builder == nil) { return nil; }
|
||||||
|
[builder setFlags:SSKProtoDataMessageFlagsUnlinkDevice];
|
||||||
|
return builder;
|
||||||
|
}
|
||||||
|
|
||||||
|
#pragma mark Settings
|
||||||
|
- (BOOL)shouldSyncTranscript { return NO; }
|
||||||
|
- (BOOL)shouldBeSaved { return NO; }
|
||||||
|
|
||||||
|
@end
|
Loading…
Reference in New Issue