[MGNLMAIL-111] Mail module sending attachments with the tmp fileName instead of original Created: 26/Feb/21  Updated: 22/Sep/21  Resolved: 08/Mar/21

Status: Closed
Project: Magnolia Mail Module
Component/s: None
Affects Version/s: 5.5.6
Fix Version/s: 5.5.7

Type: Bug Priority: Neutral
Reporter: Carlos Cantalapiedra Assignee: Quach Hao Thien
Resolution: Fixed Votes: 0
Labels: VN-Maintenance, VN-Testing, cs-bk, maintenance
Remaining Estimate: Not Specified
Time Spent: 1.25d
Original Estimate: Not Specified

Attachments: PNG File debug1.png     PNG File debug2.png     PNG File fieldName.png    
Issue Links:
Problem/Incident
Relates
Template:
Acceptance criteria:
Empty
Task DoD:
[X]* Doc/release notes changes? Comment present?
[X]* Downstream builds green?
[X]* Solution information and context easily available?
[X]* Tests
[X]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[X]* Steps to reproduce, expected, and actual results filled
[X]* Affected version filled
Date of First Response:
Sprint: Maintenance 47
Story Points: 3

 Description   

Description

When sending an attachment (e.g, at the contact form of travel site), a tmp file is created locally (at tmp folder) and when the attachment is prepared for being sent, the filename of that tmp file is taken instead of original filename uploaded at the file field.

E.g: At the Contact Form, include a File Field and name it as fileToSend (check fieldName.png image).

Now fill the form, select and attachment and send the email.

Check that the info.magnolia.module.mail.templates.MgnlMultipartEmail.addAttachment method sets as fileName the name of the file stored at the tmp folder (check debug1.png and debug2.png images).

Expected results

The filename is the original name of the file attached at the file field of the contact form

Actual results

The filename is a mix of the FIELDNAME followed of a number and the extension of the file is also changed from original to TMP

Workaround

N/A

DEV notes

N/A

 


Generated at Mon Feb 12 06:03:45 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.