mat-sz / letterparser

✉️ Isomorphic e-mail parser (with MIME support) written in TypeScript.
BSD 3-Clause Clear License
34 stars 4 forks source link

Comma in names breaks parsing RFC5322 entries #16

Closed Manouchehri closed 3 months ago

Manouchehri commented 3 months ago

e.g. when I have this in my To header:

To: "last, first (test)" <example@test.mil>

This ends up getting parsed by letterparser like:

To: undefined <"last>
To: first (test) <example@test.mil>
mat-sz commented 3 months ago

@Manouchehri I can reproduce the bug, thank you for the report.

I'm hoping to release a fix soon.

mat-sz commented 3 months ago

@Manouchehri Resolved in 0.1.5.

Looking at this again, the codebase needs a serious refactor, but it should work for now.