# HG changeset patch # User Frank-Rainer Grahl # Date 1623162001 14400 # Parent 82b7b89eebb576ccd1c6b2e55887089cd49f95ae Bug 1468492 - Part 2. Port Bug 953165 [Picture in feed not showing] to SeaMonkey. diff --git a/suite/mailnews/msgHdrViewOverlay.js b/suite/mailnews/msgHdrViewOverlay.js --- a/suite/mailnews/msgHdrViewOverlay.js +++ b/suite/mailnews/msgHdrViewOverlay.js @@ -1373,25 +1373,31 @@ function GetCardForEmail(aEmailAddress) * @param uri The URI for the message containing the attachment * @param isExternalAttachment True if the attachment has been detached * @param size The size in bytes of the attachment */ function createNewAttachmentInfo(contentType, url, displayName, uri, isExternalAttachment, size) { this.contentType = contentType; - this.url = url; this.displayName = displayName; this.uri = uri; this.isExternalAttachment = isExternalAttachment; this.attachment = this; this.size = size; let match = GlodaUtils.PART_RE.exec(url); this.partID = match && match[1]; + + // Remove [?&]part= from remote urls, after getting the partID. + if (url.startsWith("http") || url.startsWith("file")) + url = url.replace(new RegExp("[?&]part=" + this.partID + "$"), ""); + + this.url = url; + } createNewAttachmentInfo.prototype.saveAttachment = function saveAttachment() { if (this.isExternalAttachment) // TODO: This displays "Save As" instead of "Save Attachment" in the title internalSave(this.url, null, this.displayName, null,