-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixes to library to parse "some@email.com (comments) <some@email.com>" #46
Conversation
@jackbearheart gentle ping. Thanks! |
This library aims to implement RFC 5322, while OpenPGP clients are more lenient than that. I've created a fork using these commits at https://github.com/openpgpjs/email-addresses, but it might not be appropriate to include them in the original, as these User IDs are not in fact RFC 5322 compliant. |
Thanks for the PR! I appreciate you folks wanting to contribute this upstream if possible. twiss is correct in my intent here. This PR as is isn't right for this library because it would change the default behavior to be non-rfc compliant. What we could do is add an option |
ok, I will look at the option path. |
@chesnokovilya concatenating comments like you did seems reasonable |
I have updated PR. Now this feature is behind option |
@chesnokovilya Great, thank you! I haven't had the chance to merge and release this yet, but from a brief look I think it is good. I'll do this when I have a moment. |
Great |
@jackbearheart Any chance this can be merged and a new release out out soon, please? |
Yes, I'll do that now. Apologies for the delay... |
I published this in version 3.1.0. I made some minor changes to preserve backwards compatibility. Thank you! |
Awesome, thank you! |
There are a lot of mail addresses written in the form
some@email.com (comments) <some@email.com>
Currently library does not parse them correctly. (it would output
undefined
when parsing this name)This is causing some issues with pgp (pretty good privacy) realisations:
openpgpjs/openpgpjs#918
In this pull request I fix this behaviour to correctly parse displayName with
@
. Secondly comments are correctly parsed and outputted as concatenated string.