mirror of
https://github.com/Unstructured-IO/unstructured.git
synced 2025-06-27 02:30:08 +00:00

Handle Content-Disposition: inline and attachment without filename * Add new email test example and test with Content-Disposition: inline. * Move attachment_info above for loop so it is always defined * Check if item is inline as well as attachment as these both lack an = character to split on * Create filename if filename is not specified and write file. * Update list_attachments with new filename
24 lines
657 B
Plaintext
24 lines
657 B
Plaintext
From: Test User <testuser@example.com>
|
|
To: recipient@example.com
|
|
Subject: Testing Inline
|
|
Message-ID: <CAPgCCDEzLVJ-d1OCX_TjFgJU7ugtQrjFybPtAMmmYZzphxNFYg@mail.example.com>
|
|
X-Mailer: Claws Mail 4.1.1 (GTK 3.24.34; x86_64-pc-linux-gnu)
|
|
MIME-Version: 1.0
|
|
Content-Type: multipart/mixed; boundary="MP_/pqqQE0ldE7RYQcFW3Kd0aQV"
|
|
|
|
--MP_/pqqQE0ldE7RYQcFW3Kd0aQV
|
|
Content-Type: text/plain; charset=US-ASCII
|
|
Content-Transfer-Encoding: 7bit
|
|
Content-Disposition: inline
|
|
|
|
This is a test of inline
|
|
|
|
--MP_/pqqQE0ldE7RYQcFW3Kd0aQV
|
|
Content-Type: text/plain
|
|
Content-Transfer-Encoding: 7bit
|
|
Content-Disposition: attachment; filename=t.txt
|
|
|
|
test
|
|
|
|
--MP_/pqqQE0ldE7RYQcFW3Kd0aQV--
|