-
-
Notifications
You must be signed in to change notification settings - Fork 40
Open
Description
The RFC for Mails requires all lines in the Message to not be longer than 1000 characters (including CR+LF).
If I create a Message with this library, I would expect line-breaks to be added automatically to conform to the standard.
But the library does not add line-breaks to the message body and this emails are rejected by many mail servers with the error "501: line too long"
Example code:
const mimeText = require('mimetext')
const msg = mimeText.createMimeMessage()
msg.setSender('test@example.org')
msg.setTo('test@example.org')
msg.setSubject('This message will be rejected')
msg.addMessage({ contentType: 'text/html', data: 'x'.repeat(2000) })
console.log(msg.asRaw())
This message will contain a single line with 2000 characters, breaking the spec.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels