Skip to content

Commit

Permalink
chore(sqlite): replace double-quoted literals with single-quoted ones (
Browse files Browse the repository at this point in the history
…#2420) (#2425)

Co-authored-by: Vitor Hugo Schwaab <[email protected]>
Co-authored-by: Yamil Medina <[email protected]>
  • Loading branch information
3 people authored Jan 31, 2024
1 parent bf8db0b commit 48c3ad2
Show file tree
Hide file tree
Showing 15 changed files with 55 additions and 55 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ SELECT *
CREATE TRIGGER updateConversationProteusVerificationStatus
AFTER UPDATE ON Client
BEGIN
UPDATE Conversation SET proteus_verification_status = (CASE (new.is_verified) WHEN 1 THEN "VERIFIED" ELSE "DEGRADED" END)
UPDATE Conversation SET proteus_verification_status = (CASE (new.is_verified) WHEN 1 THEN 'VERIFIED' ELSE 'DEGRADED' END)
WHERE qualified_id IN (
SELECT id FROM (SELECT
conv.qualified_id AS id,
Expand All @@ -106,14 +106,14 @@ BEGIN
LEFT JOIN Client ON Client.user_id = Member.user
WHERE Client.id = new.id)
GROUP BY conv.qualified_id)
WHERE (CASE (verificationStatus) WHEN "VERIFIED" THEN 1 ELSE 0 END) != isActuallyVerified
WHERE (CASE (verificationStatus) WHEN 'VERIFIED' THEN 1 ELSE 0 END) != isActuallyVerified
);
END;

CREATE TRIGGER updateConversationProteusVerificationStatusAfterNewClient
AFTER INSERT ON Client
BEGIN
UPDATE Conversation SET proteus_verification_status = "DEGRADED"
UPDATE Conversation SET proteus_verification_status = 'DEGRADED'
WHERE qualified_id IN (
SELECT Member.conversation FROM Member
LEFT JOIN Client ON Client.user_id = Member.user
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ CREATE TABLE Conversation (
archived INTEGER AS Boolean NOT NULL DEFAULT 0,
archived_date_time INTEGER AS Instant,
-- mls_verification_status
verification_status TEXT AS ConversationEntity.VerificationStatus NOT NULL DEFAULT "NOT_VERIFIED",
proteus_verification_status TEXT AS ConversationEntity.VerificationStatus NOT NULL DEFAULT "NOT_VERIFIED",
verification_status TEXT AS ConversationEntity.VerificationStatus NOT NULL DEFAULT 'NOT_VERIFIED',
proteus_verification_status TEXT AS ConversationEntity.VerificationStatus NOT NULL DEFAULT 'NOT_VERIFIED',
degraded_conversation_notified INTEGER AS Boolean NOT NULL DEFAULT 1,
legal_hold_status TEXT AS ConversationEntity.LegalHoldStatus NOT NULL DEFAULT "DISABLED"
legal_hold_status TEXT AS ConversationEntity.LegalHoldStatus NOT NULL DEFAULT 'DISABLED'
);

CREATE TABLE ConversationLegalHoldStatusChangeNotified (
Expand Down Expand Up @@ -304,7 +304,7 @@ selectByGroupId:
SELECT * FROM ConversationDetails WHERE mls_group_id = ?;

selectByGroupState:
SELECT * FROM ConversationDetails WHERE mls_group_state = ? AND (protocol IS "MLS" OR protocol IS "MIXED");
SELECT * FROM ConversationDetails WHERE mls_group_state = ? AND (protocol IS 'MLS' OR protocol IS 'MIXED');

selectActiveOneOnOneConversation:
SELECT * FROM ConversationDetails
Expand Down Expand Up @@ -338,7 +338,7 @@ updateKeyingMaterialDate:
UPDATE Conversation SET mls_last_keying_material_update_date= ? WHERE mls_group_id = ?;

selectByKeyingMaterialUpdate:
SELECT mls_group_id FROM Conversation WHERE mls_group_state = ? AND (protocol IS "MLS" OR protocol IS "MIXED") AND mls_last_keying_material_update_date - ? <0 AND mls_group_id IS NOT NULL;
SELECT mls_group_id FROM Conversation WHERE mls_group_state = ? AND (protocol IS 'MLS' OR protocol IS 'MIXED') AND mls_last_keying_material_update_date - ? <0 AND mls_group_id IS NOT NULL;

updateProposalTimer:
UPDATE Conversation SET mls_proposal_timer = COALESCE(mls_proposal_timer, ?) WHERE mls_group_id = ?;
Expand All @@ -347,7 +347,7 @@ clearProposalTimer:
UPDATE Conversation SET mls_proposal_timer = NULL WHERE mls_group_id = ?;

selectProposalTimers:
SELECT mls_group_id, mls_proposal_timer FROM Conversation WHERE (protocol IS "MLS" OR protocol IS "MIXED") AND mls_group_id IS NOT NULL AND mls_proposal_timer IS NOT NULL;
SELECT mls_group_id, mls_proposal_timer FROM Conversation WHERE (protocol IS 'MLS' OR protocol IS 'MIXED') AND mls_group_id IS NOT NULL AND mls_proposal_timer IS NOT NULL;

whoDeletedMeInConversation:
SELECT sender_user_id FROM Message WHERE id IN (SELECT message_id FROM MessageMemberChangeContent WHERE conversation_id = :conversation_id AND member_change_type = 'REMOVED' AND member_change_list LIKE ('%' || :self_user_id || '%')) ORDER BY creation_date DESC LIMIT 1;
Expand Down Expand Up @@ -464,26 +464,26 @@ SELECT changes();
CREATE TRIGGER addMessageAfterProteusVerificationStatusChange
AFTER UPDATE ON Conversation
WHEN new.proteus_verification_status != old.proteus_verification_status
AND (new.proteus_verification_status = "VERIFIED" OR old.proteus_verification_status = "VERIFIED")
AND (new.proteus_verification_status = 'VERIFIED' OR old.proteus_verification_status = 'VERIFIED')
BEGIN
INSERT OR IGNORE INTO Message(id, content_type, conversation_id, creation_date, sender_user_id, sender_client_id, status, visibility)
VALUES(
(SELECT lower(hex(randomblob(4)) || '-' || lower(hex(randomblob(2))) || '-4' ||
substr(lower(hex(randomblob(2))),2) || '-a' || substr(lower(hex(randomblob(2))),2)
|| '-' || lower(hex(randomblob(6))))),
(CASE (new.proteus_verification_status)
WHEN "VERIFIED" THEN "CONVERSATION_VERIFIED_PROTEUS"
ELSE "CONVERSATION_DEGRADED_PROTEUS" END
WHEN 'VERIFIED' THEN 'CONVERSATION_VERIFIED_PROTEUS'
ELSE 'CONVERSATION_DEGRADED_PROTEUS' END
),
new.qualified_id,
(SELECT CAST((julianday('now') - 2440587.5) * 86400 * 1000 AS INTEGER)),
(SELECT SelfUser.id FROM SelfUser LIMIT 1),
(SELECT Client.id FROM Client WHERE Client.user_id = (SELECT SelfUser.id FROM SelfUser LIMIT 1) LIMIT 1),
"SENT",
"VISIBLE"
'SENT',
'VISIBLE'
);

UPDATE Conversation
SET degraded_conversation_notified = (new.proteus_verification_status != "DEGRADED")
SET degraded_conversation_notified = (new.proteus_verification_status != 'DEGRADED')
WHERE qualified_id = new.qualified_id;
END;
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,8 @@ BEGIN
LEFT JOIN Client AS client ON client.user_id = mem.user
WHERE mem.conversation = new.conversation
GROUP BY mem.conversation)
WHEN 1 THEN "VERIFIED"
ELSE "DEGRADED" END)
WHEN 1 THEN 'VERIFIED'
ELSE 'DEGRADED' END)
WHERE qualified_id = new.conversation;
END;

Expand All @@ -113,8 +113,8 @@ BEGIN
LEFT JOIN Client AS client ON client.user_id = mem.user
WHERE mem.conversation = old.conversation
GROUP BY mem.conversation)
WHEN 1 THEN "VERIFIED"
ELSE "DEGRADED" END)
WHEN 1 THEN 'VERIFIED'
ELSE 'DEGRADED' END)
WHERE qualified_id = old.conversation;
END;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Message.expects_read_confirmation AS expectsReadConfirmation,
Message.expire_after_millis AS expireAfterMillis,
Message.self_deletion_start_date AS selfDeletionStartDate,
Message.self_deletion_end_date AS selfDeletionEndDate,
IFNULL ((SELECT COUNT (*) FROM Receipt WHERE message_id = Message.id AND type = "READ"), 0) AS readCount,
IFNULL ((SELECT COUNT (*) FROM Receipt WHERE message_id = Message.id AND type = 'READ'), 0) AS readCount,
User.name AS senderName,
User.handle AS senderHandle,
User.email AS senderEmail,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -211,20 +211,20 @@ WHERE NOT EXISTS (SELECT user FROM Member AS member WHERE member.conversation ==
AND (name LIKE ('%' || :searchQuery || '%')
OR handle LIKE ('%' || :searchQuery || '%')
OR email LIKE ('%' || :searchQuery || '%'))
AND connection_status = "ACCEPTED"
AND connection_status = 'ACCEPTED'
AND defederated = 0;

getUsersNotInConversationByHandle:
SELECT * FROM UserDetails AS user
WHERE NOT EXISTS (SELECT user FROM Member AS member WHERE member.conversation == :converastion_id AND user.qualified_id == member.user)
AND handle LIKE ('%' || :searchQuery || '%')
AND connection_status = "ACCEPTED"
AND connection_status = 'ACCEPTED'
AND defederated = 0;

getUsersNotPartOfTheConversation:
SELECT * FROM UserDetails AS user
WHERE NOT EXISTS (SELECT user FROM Member AS member WHERE member.conversation == :converastion_id AND user.qualified_id == member.user)
AND connection_status = "ACCEPTED"
AND connection_status = 'ACCEPTED'
AND defederated = 0;

updateUserDisplayName:
Expand Down
2 changes: 1 addition & 1 deletion persistence/src/commonMain/db_user/migrations/54.sqm
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Message.visibility AS visibility,
Message.expects_read_confirmation AS expectsReadConfirmation,
Message.expire_after_millis AS expireAfterMillis,
Message.self_deletion_start_date AS selfDeletionStartDate,
IFNULL ((SELECT COUNT (*) FROM Receipt WHERE message_id = Message.id AND type = "READ"), 0) AS readCount,
IFNULL ((SELECT COUNT (*) FROM Receipt WHERE message_id = Message.id AND type = 'READ'), 0) AS readCount,
User.name AS senderName,
User.handle AS senderHandle,
User.email AS senderEmail,
Expand Down
2 changes: 1 addition & 1 deletion persistence/src/commonMain/db_user/migrations/55.sqm
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ Message.visibility AS visibility,
Message.expects_read_confirmation AS expectsReadConfirmation,
Message.expire_after_millis AS expireAfterMillis,
Message.self_deletion_start_date AS selfDeletionStartDate,
IFNULL ((SELECT COUNT (*) FROM Receipt WHERE message_id = Message.id AND type = "READ"), 0) AS readCount,
IFNULL ((SELECT COUNT (*) FROM Receipt WHERE message_id = Message.id AND type = 'READ'), 0) AS readCount,
User.name AS senderName,
User.handle AS senderHandle,
User.email AS senderEmail,
Expand Down
2 changes: 1 addition & 1 deletion persistence/src/commonMain/db_user/migrations/58.sqm
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import com.wire.kalium.persistence.dao.conversation.ConversationEntity;

ALTER TABLE Conversation ADD COLUMN verification_status TEXT AS ConversationEntity.VerificationStatus NOT NULL DEFAULT "NOT_VERIFIED" ;
ALTER TABLE Conversation ADD COLUMN verification_status TEXT AS ConversationEntity.VerificationStatus NOT NULL DEFAULT 'NOT_VERIFIED' ;

DROP VIEW IF EXISTS ConversationDetails;

Expand Down
2 changes: 1 addition & 1 deletion persistence/src/commonMain/db_user/migrations/62.sqm
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Message.visibility AS visibility,
Message.expects_read_confirmation AS expectsReadConfirmation,
Message.expire_after_millis AS expireAfterMillis,
Message.self_deletion_start_date AS selfDeletionStartDate,
IFNULL ((SELECT COUNT (*) FROM Receipt WHERE message_id = Message.id AND type = "READ"), 0) AS readCount,
IFNULL ((SELECT COUNT (*) FROM Receipt WHERE message_id = Message.id AND type = 'READ'), 0) AS readCount,
User.name AS senderName,
User.handle AS senderHandle,
User.email AS senderEmail,
Expand Down
16 changes: 8 additions & 8 deletions persistence/src/commonMain/db_user/migrations/63.sqm
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import com.wire.kalium.persistence.dao.conversation.ConversationEntity;

ALTER TABLE Conversation ADD COLUMN proteus_verification_status TEXT AS ConversationEntity.VerificationStatus NOT NULL DEFAULT "NOT_VERIFIED";
ALTER TABLE Conversation ADD COLUMN proteus_verification_status TEXT AS ConversationEntity.VerificationStatus NOT NULL DEFAULT 'NOT_VERIFIED';

DROP VIEW IF EXISTS ConversationDetails;

Expand Down Expand Up @@ -113,7 +113,7 @@ LEFT JOIN Call ON Call.id IS (SELECT id FROM Call WHERE Call.conversation_id = C
CREATE TRIGGER updateConversationProteusVerificationStatus
AFTER UPDATE ON Client
BEGIN
UPDATE Conversation SET proteus_verification_status = (CASE (new.is_verified) WHEN 1 THEN "VERIFIED" ELSE "DEGRADED" END)
UPDATE Conversation SET proteus_verification_status = (CASE (new.is_verified) WHEN 1 THEN 'VERIFIED' ELSE 'DEGRADED' END)
WHERE qualified_id IN (
SELECT id FROM (SELECT conv.qualified_id AS id, conv.proteus_verification_status AS verificationStatus, (COUNT(*) = SUM(CASE WHEN client.is_verified = 1 THEN 1 ELSE 0 END)) AS isActuallyVerified
FROM Conversation AS conv
Expand All @@ -124,14 +124,14 @@ BEGIN
WHERE Client.id = new.id)
AND mem.user IS NOT (SELECT SelfUser.id FROM SelfUser LIMIT 1)
GROUP BY conv.qualified_id)
WHERE (CASE (verificationStatus) WHEN "VERIFIED" THEN 1 ELSE 0 END) != isActuallyVerified
WHERE (CASE (verificationStatus) WHEN 'VERIFIED' THEN 1 ELSE 0 END) != isActuallyVerified
);
END;

CREATE TRIGGER updateConversationProteusVerificationStatusAfterNewClient
AFTER INSERT ON Client
BEGIN
UPDATE Conversation SET proteus_verification_status = "DEGRADED"
UPDATE Conversation SET proteus_verification_status = 'DEGRADED'
WHERE qualified_id IN (
SELECT Member.conversation FROM Member
LEFT JOIN Client ON Client.user_id = Member.user
Expand All @@ -149,14 +149,14 @@ BEGIN
substr(lower(hex(randomblob(2))),2) || '-a' || substr(lower(hex(randomblob(2))),2)
|| '-' || lower(hex(randomblob(6))))),
(CASE (new.proteus_verification_status)
WHEN "VERIFIED" THEN "CONVERSATION_VERIFIED_PROTEUS"
ELSE "CONVERSATION_DEGRADED_PROTEUS" END
WHEN 'VERIFIED' THEN 'CONVERSATION_VERIFIED_PROTEUS'
ELSE 'CONVERSATION_DEGRADED_PROTEUS' END
),
new.qualified_id,
(SELECT CAST((julianday('now') - 2440587.5) * 86400 * 1000 AS INTEGER)),
(SELECT SelfUser.id FROM SelfUser LIMIT 1),
(SELECT Client.id FROM Client WHERE Client.user_id = (SELECT SelfUser.id FROM SelfUser LIMIT 1) LIMIT 1),
"SENT",
"VISIBLE"
'SENT',
'VISIBLE'
);
END;
22 changes: 11 additions & 11 deletions persistence/src/commonMain/db_user/migrations/64.sqm
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ DROP TRIGGER IF EXISTS addMessageAfterProteusVerificationStatusChange;
CREATE TRIGGER updateConversationProteusVerificationStatus
AFTER UPDATE ON Client
BEGIN
UPDATE Conversation SET proteus_verification_status = (CASE (new.is_verified) WHEN 1 THEN "VERIFIED" ELSE "DEGRADED" END)
UPDATE Conversation SET proteus_verification_status = (CASE (new.is_verified) WHEN 1 THEN 'VERIFIED' ELSE 'DEGRADED' END)
WHERE qualified_id IN (
SELECT id FROM (SELECT
conv.qualified_id AS id,
Expand All @@ -18,30 +18,30 @@ BEGIN
LEFT JOIN Client ON Client.user_id = Member.user
WHERE Client.id = new.id)
GROUP BY conv.qualified_id)
WHERE (CASE (verificationStatus) WHEN "VERIFIED" THEN 1 ELSE 0 END) != isActuallyVerified
WHERE (CASE (verificationStatus) WHEN 'VERIFIED' THEN 1 ELSE 0 END) != isActuallyVerified
);
END;

CREATE TRIGGER addMessageAfterProteusVerificationStatusChange
AFTER UPDATE ON Conversation
WHEN new.proteus_verification_status != old.proteus_verification_status
AND (new.proteus_verification_status = "VERIFIED" OR old.proteus_verification_status = "VERIFIED")
AND (new.proteus_verification_status = 'VERIFIED' OR old.proteus_verification_status = 'VERIFIED')
BEGIN
INSERT OR IGNORE INTO Message(id, content_type, conversation_id, creation_date, sender_user_id, sender_client_id, status, visibility)
VALUES(
(SELECT lower(hex(randomblob(4)) || '-' || lower(hex(randomblob(2))) || '-4' ||
substr(lower(hex(randomblob(2))),2) || '-a' || substr(lower(hex(randomblob(2))),2)
|| '-' || lower(hex(randomblob(6))))),
(CASE (new.proteus_verification_status)
WHEN "VERIFIED" THEN "CONVERSATION_VERIFIED_PROTEUS"
ELSE "CONVERSATION_DEGRADED_PROTEUS" END
WHEN 'VERIFIED' THEN 'CONVERSATION_VERIFIED_PROTEUS'
ELSE 'CONVERSATION_DEGRADED_PROTEUS' END
),
new.qualified_id,
(SELECT CAST((julianday('now') - 2440587.5) * 86400 * 1000 AS INTEGER)),
(SELECT SelfUser.id FROM SelfUser LIMIT 1),
(SELECT Client.id FROM Client WHERE Client.user_id = (SELECT SelfUser.id FROM SelfUser LIMIT 1) LIMIT 1),
"SENT",
"VISIBLE"
'SENT',
'VISIBLE'
);
END;

Expand All @@ -56,8 +56,8 @@ BEGIN
LEFT JOIN Client AS client ON client.user_id = mem.user
WHERE mem.conversation = new.conversation
GROUP BY mem.conversation)
WHEN 1 THEN "VERIFIED"
ELSE "DEGRADED" END)
WHEN 1 THEN 'VERIFIED'
ELSE 'DEGRADED' END)
WHERE qualified_id = new.conversation;
END;

Expand All @@ -72,7 +72,7 @@ BEGIN
LEFT JOIN Client AS client ON client.user_id = mem.user
WHERE mem.conversation = old.conversation
GROUP BY mem.conversation)
WHEN 1 THEN "VERIFIED"
ELSE "DEGRADED" END)
WHEN 1 THEN 'VERIFIED'
ELSE 'DEGRADED' END)
WHERE qualified_id = old.conversation;
END;
12 changes: 6 additions & 6 deletions persistence/src/commonMain/db_user/migrations/65.sqm
Original file line number Diff line number Diff line change
Expand Up @@ -8,26 +8,26 @@ DROP TRIGGER IF EXISTS addMessageAfterProteusVerificationStatusChange;
CREATE TRIGGER addMessageAfterProteusVerificationStatusChange
AFTER UPDATE ON Conversation
WHEN new.proteus_verification_status != old.proteus_verification_status
AND (new.proteus_verification_status = "VERIFIED" OR old.proteus_verification_status = "VERIFIED")
AND (new.proteus_verification_status = 'VERIFIED' OR old.proteus_verification_status = 'VERIFIED')
BEGIN
INSERT OR IGNORE INTO Message(id, content_type, conversation_id, creation_date, sender_user_id, sender_client_id, status, visibility)
VALUES(
(SELECT lower(hex(randomblob(4)) || '-' || lower(hex(randomblob(2))) || '-4' ||
substr(lower(hex(randomblob(2))),2) || '-a' || substr(lower(hex(randomblob(2))),2)
|| '-' || lower(hex(randomblob(6))))),
(CASE (new.proteus_verification_status)
WHEN "VERIFIED" THEN "CONVERSATION_VERIFIED_PROTEUS"
ELSE "CONVERSATION_DEGRADED_PROTEUS" END
WHEN 'VERIFIED' THEN 'CONVERSATION_VERIFIED_PROTEUS'
ELSE 'CONVERSATION_DEGRADED_PROTEUS' END
),
new.qualified_id,
(SELECT CAST((julianday('now') - 2440587.5) * 86400 * 1000 AS INTEGER)),
(SELECT SelfUser.id FROM SelfUser LIMIT 1),
(SELECT Client.id FROM Client WHERE Client.user_id = (SELECT SelfUser.id FROM SelfUser LIMIT 1) LIMIT 1),
"SENT",
"VISIBLE"
'SENT',
'VISIBLE'
);

UPDATE Conversation
SET degraded_conversation_notified = (new.proteus_verification_status != "DEGRADED")
SET degraded_conversation_notified = (new.proteus_verification_status != 'DEGRADED')
WHERE qualified_id = new.qualified_id;
END;
2 changes: 1 addition & 1 deletion persistence/src/commonMain/db_user/migrations/66.sqm
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import com.wire.kalium.persistence.dao.conversation.ConversationEntity;

ALTER TABLE Conversation ADD COLUMN legal_hold_status TEXT AS ConversationEntity.LegalHoldStatus NOT NULL DEFAULT "DISABLED";
ALTER TABLE Conversation ADD COLUMN legal_hold_status TEXT AS ConversationEntity.LegalHoldStatus NOT NULL DEFAULT 'DISABLED';

DROP VIEW IF EXISTS ConversationDetails;

Expand Down
2 changes: 1 addition & 1 deletion persistence/src/commonMain/db_user/migrations/70.sqm
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Message.visibility AS visibility,
Message.expects_read_confirmation AS expectsReadConfirmation,
Message.expire_after_millis AS expireAfterMillis,
Message.self_deletion_start_date AS selfDeletionStartDate,
IFNULL ((SELECT COUNT (*) FROM Receipt WHERE message_id = Message.id AND type = "READ"), 0) AS readCount,
IFNULL ((SELECT COUNT (*) FROM Receipt WHERE message_id = Message.id AND type = 'READ'), 0) AS readCount,
User.name AS senderName,
User.handle AS senderHandle,
User.email AS senderEmail,
Expand Down
2 changes: 1 addition & 1 deletion persistence/src/commonMain/db_user/migrations/73.sqm
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Message.expects_read_confirmation AS expectsReadConfirmation,
Message.expire_after_millis AS expireAfterMillis,
Message.self_deletion_start_date AS selfDeletionStartDate,
Message.self_deletion_end_date AS selfDeletionEndDate,
IFNULL ((SELECT COUNT (*) FROM Receipt WHERE message_id = Message.id AND type = "READ"), 0) AS readCount,
IFNULL ((SELECT COUNT (*) FROM Receipt WHERE message_id = Message.id AND type = 'READ'), 0) AS readCount,
User.name AS senderName,
User.handle AS senderHandle,
User.email AS senderEmail,
Expand Down

0 comments on commit 48c3ad2

Please sign in to comment.