Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion extension/js/common/core/attachment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,11 @@ export class Attachment {
return 'signature';
} else if (this.inline && this.isImage()) {
return 'inlineImage';
} else if (!this.name && !this.isImage() && !['application/octet-stream', 'multipart/mixed', 'message/global'].includes(this.type)) {
} else if (!this.name && !['application/octet-stream', 'multipart/mixed', 'message/global'].includes(this.type)) {
// this is a noname attachment, but treat them as 'plainFile' if body is not empty. therefore, the attachment can't be concluded as pgp message
if (!isBodyEmpty) {
return 'plainFile';
}
// this.name may be '' or undefined - catch either
return this.length < 100 ? 'hidden' : 'encryptedMsg';
} else if (this.name === 'msg.asc' && this.length < 100 && this.type === 'application/pgp-encrypted') {
Expand Down
Loading