|
|
@ -12,12 +12,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
@implementation LKAddressMessage
|
|
|
|
@implementation LKAddressMessage
|
|
|
|
|
|
|
|
|
|
|
|
- (instancetype)initAddressMessageInThread:(nullable TSThread *)thread
|
|
|
|
- (instancetype)initInThread:(nullable TSThread *)thread
|
|
|
|
address:(NSString *)address
|
|
|
|
address:(NSString *)address
|
|
|
|
port:(uint)port
|
|
|
|
port:(uint)port
|
|
|
|
{
|
|
|
|
{
|
|
|
|
self = [super initOutgoingMessageWithTimestamp:NSDate.ows_millisecondTimeStamp inThread:thread messageBody:nil attachmentIds:[NSMutableArray<NSString *> new]
|
|
|
|
self = [super initInThread:thread];
|
|
|
|
expiresInSeconds:0 expireStartedAt:0 isVoiceMessage:NO groupMetaMessage:TSGroupMetaMessageUnspecified quotedMessage:nil contactShare:nil linkPreview:nil];
|
|
|
|
|
|
|
|
if (!self) {
|
|
|
|
if (!self) {
|
|
|
|
return self;
|
|
|
|
return self;
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -47,13 +46,6 @@
|
|
|
|
return contentBuilder;
|
|
|
|
return contentBuilder;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// We don't need to send any data message in this address message
|
|
|
|
|
|
|
|
- (nullable SSKProtoDataMessage *)buildDataMessage:(NSString *_Nullable)recipientId {
|
|
|
|
|
|
|
|
return nil;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
- (BOOL)shouldBeSaved { return false; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
- (uint)ttl {
|
|
|
|
- (uint)ttl {
|
|
|
|
// Address messages should only last 1 minute
|
|
|
|
// Address messages should only last 1 minute
|
|
|
|
return 1 * kMinuteInterval;
|
|
|
|
return 1 * kMinuteInterval;
|
|
|
|