Relax document requirements for media gallery

This commit is contained in:
Fedor Indutny
2026-04-20 13:01:51 -07:00
committed by GitHub
parent 5f6edbdaae
commit ccf899f70d
2 changed files with 0 additions and 6 deletions
-2
View File
@@ -5583,8 +5583,6 @@ function getSortedMedia(
// see 'isFile' in ts/util/Attachment.std.ts
contentFilter = sqlFragment`
message_attachments.flags IS NOT ${VOICE_MESSAGE} AND
message_attachments.contentType IS NOT NULL AND
message_attachments.contentType IS NOT '' AND
message_attachments.contentType IS NOT 'text/x-signal-plain' AND
message_attachments.contentType NOT LIKE 'audio/%' AND
message_attachments.contentType NOT LIKE 'image/%' AND
-4
View File
@@ -542,10 +542,6 @@ export const isVisualMedia = (attachment: AttachmentType): boolean => {
export const isFile = (attachment: AttachmentType): boolean => {
const { contentType } = attachment;
if (isUndefined(contentType)) {
return false;
}
if (isVisualMedia(attachment)) {
return false;
}