Index: chrome/browser/resources/options/chromeos/accounts_user_name_edit.js |
diff --git a/chrome/browser/resources/options/chromeos/accounts_user_name_edit.js b/chrome/browser/resources/options/chromeos/accounts_user_name_edit.js |
index 6766e969ad5ed792c4761808f100667491a2214d..94cb292002368aa444e1ec1600863a4d290a8026 100644 |
--- a/chrome/browser/resources/options/chromeos/accounts_user_name_edit.js |
+++ b/chrome/browser/resources/options/chromeos/accounts_user_name_edit.js |
@@ -17,8 +17,7 @@ cr.define('options.accounts', function() { |
* {name: 'john', email: 'john@chromium.org'} |
* @const |
*/ |
- var format2String = |
- '^\\s*([\\w\\.!#\\$%&\'\\*\\+-\\/=\\?\\^`\\{\\|\\}~]+)@' + |
+ var format2String = '^\\s*([\\w\\.!#\\$%&\'\\*\\+-\\/=\\?\\^`\\{\\|\\}~]+)@' + |
'([A-Za-z0-9\-]{2,63}\\..+)\\s*$'; |
/** |
* Full format. |
@@ -26,8 +25,7 @@ cr.define('options.accounts', function() { |
* {name: 'John doe', email: 'john@chromium.org'} |
* @const |
*/ |
- var format3String = |
- '^\\s*"{0,1}([^"]+)"{0,1}\\s*' + |
+ var format3String = '^\\s*"{0,1}([^"]+)"{0,1}\\s*' + |
'<([\\w\\.!#\\$%&\'\\*\\+-\\/=\\?\\^`\\{\\|\\}~]+@' + |
'[A-Za-z0-9\-]{2,63}\\..+)>\\s*$'; |
@@ -46,8 +44,7 @@ cr.define('options.accounts', function() { |
* Called when an element is decorated as a user name edit. |
*/ |
decorate: function() { |
- this.pattern = format1String + '|' + format2String + '|' + |
- format3String; |
+ this.pattern = format1String + '|' + format2String + '|' + format3String; |
this.onkeydown = this.handleKeyDown_.bind(this); |
}, |
@@ -77,26 +74,17 @@ cr.define('options.accounts', function() { |
var matches = format1.exec(str); |
if (matches) { |
- return { |
- name: matches[1], |
- email: matches[1] + '@gmail.com' |
- }; |
+ return {name: matches[1], email: matches[1] + '@gmail.com'}; |
} |
matches = format2.exec(str); |
if (matches) { |
- return { |
- name: matches[1], |
- email: matches[1] + '@' + matches[2] |
- }; |
+ return {name: matches[1], email: matches[1] + '@' + matches[2]}; |
} |
matches = format3.exec(str); |
if (matches) { |
- return { |
- name: matches[1], |
- email: matches[2] |
- }; |
+ return {name: matches[1], email: matches[2]}; |
} |
return null; |
@@ -122,8 +110,5 @@ cr.define('options.accounts', function() { |
} |
}; |
- return { |
- UserNameEdit: UserNameEdit |
- }; |
+ return {UserNameEdit: UserNameEdit}; |
}); |
- |