Merge pull request #833 from mpretty-cyro/fix/incorrect-status-query

Fix recipientState query bug
pull/836/head
Morgan Pretty 3 years ago committed by GitHub
commit 39b005172b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -527,11 +527,11 @@ public extension SessionThreadViewModel {
WHERE (
\(recipientState[.interactionId]) = \(interaction[.id]) AND
-- Ignore 'skipped' states
\(SQL("\(recipientState[.state]) = \(RecipientState.State.sending)"))
\(SQL("\(recipientState[.state]) != \(RecipientState.State.skipped)"))
)
LIMIT 1
), 0) AS \(ViewModel.interactionStateKey),
), \(SQL("\(RecipientState.State.sending)"))) AS \(ViewModel.interactionStateKey),
(\(readReceiptTableLiteral).\(readReceiptReadTimestampMsColumnLiteral) IS NOT NULL) AS \(ViewModel.interactionHasAtLeastOneReadReceiptKey),
(\(linkPreview[.url]) IS NOT NULL) AS \(ViewModel.interactionIsOpenGroupInvitationKey),

Loading…
Cancel
Save