Bug 286760 - email address with leading/trailing whitespace in Address book, Account manager, or Composition [foo@bar.com ] displays wrongly with added quotes when composing ["foo"@bar.com], causing lost mails and malformed "duplicate" AB entry. r=jcranmer, a=mkmelin
This puch lands string changes to CLOSED TREE (seamonkey)
This commit is contained in:
Родитель
6f2605fc5c
Коммит
e30a4cd4d7
|
@ -300,7 +300,7 @@ MimeAddressParser.prototype = {
|
|||
makeMailboxObject: function (aName, aEmail) {
|
||||
let object = Object.create(Mailbox);
|
||||
object.name = aName;
|
||||
object.email = aEmail;
|
||||
object.email = aEmail ? aEmail.trim() : aEmail;
|
||||
return object;
|
||||
},
|
||||
|
||||
|
|
|
@ -20,6 +20,10 @@ function run_test() {
|
|||
"\"Joe Q. Public\" <john.q.public@example.com>"],
|
||||
["Giant; \"Big\" Box", "sysservices@example.net",
|
||||
"\"Giant; \\\"Big\\\" Box\" <sysservices@example.net>"],
|
||||
["trailing", "t1@example.com ", "trailing <t1@example.com>"],
|
||||
["leading", " t2@example.com", "leading <t2@example.com>"],
|
||||
["leading trailing", " t3@example.com ", "leading trailing <t3@example.com>"],
|
||||
["", " t4@example.com ", "t4@example.com"],
|
||||
];
|
||||
|
||||
// Test - empty strings
|
||||
|
|
Загрузка…
Ссылка в новой задаче