|
|
@ -369,6 +369,12 @@ extension ConversationVC:
|
|
|
|
body: text,
|
|
|
|
body: text,
|
|
|
|
timestampMs: sentTimestampMs,
|
|
|
|
timestampMs: sentTimestampMs,
|
|
|
|
hasMention: Interaction.isUserMentioned(db, threadId: threadId, body: text),
|
|
|
|
hasMention: Interaction.isUserMentioned(db, threadId: threadId, body: text),
|
|
|
|
|
|
|
|
expiresInSeconds: try? DisappearingMessagesConfiguration
|
|
|
|
|
|
|
|
.select(.durationSeconds)
|
|
|
|
|
|
|
|
.filter(id: threadId)
|
|
|
|
|
|
|
|
.filter(DisappearingMessagesConfiguration.Columns.isEnabled == true)
|
|
|
|
|
|
|
|
.asRequest(of: TimeInterval.self)
|
|
|
|
|
|
|
|
.fetchOne(db),
|
|
|
|
linkPreviewUrl: linkPreviewDraft?.urlString
|
|
|
|
linkPreviewUrl: linkPreviewDraft?.urlString
|
|
|
|
).inserted(db)
|
|
|
|
).inserted(db)
|
|
|
|
|
|
|
|
|
|
|
@ -459,7 +465,13 @@ extension ConversationVC:
|
|
|
|
variant: .standardOutgoing,
|
|
|
|
variant: .standardOutgoing,
|
|
|
|
body: text,
|
|
|
|
body: text,
|
|
|
|
timestampMs: sentTimestampMs,
|
|
|
|
timestampMs: sentTimestampMs,
|
|
|
|
hasMention: Interaction.isUserMentioned(db, threadId: threadId, body: text)
|
|
|
|
hasMention: Interaction.isUserMentioned(db, threadId: threadId, body: text),
|
|
|
|
|
|
|
|
expiresInSeconds: try? DisappearingMessagesConfiguration
|
|
|
|
|
|
|
|
.select(.durationSeconds)
|
|
|
|
|
|
|
|
.filter(id: threadId)
|
|
|
|
|
|
|
|
.filter(DisappearingMessagesConfiguration.Columns.isEnabled == true)
|
|
|
|
|
|
|
|
.asRequest(of: TimeInterval.self)
|
|
|
|
|
|
|
|
.fetchOne(db)
|
|
|
|
).inserted(db)
|
|
|
|
).inserted(db)
|
|
|
|
|
|
|
|
|
|
|
|
try MessageSender.send(
|
|
|
|
try MessageSender.send(
|
|
|
|