Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7512)

Unified Diff: chrome/browser/resources/options/autofill_edit_creditcard_overlay.js

Issue 553573003: Compile chrome://settings, part 3: 167 proper errors left (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@G_options_errors_1
Patch Set: fixed crash on assertInstanceof Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/options/autofill_edit_creditcard_overlay.js
diff --git a/chrome/browser/resources/options/autofill_edit_creditcard_overlay.js b/chrome/browser/resources/options/autofill_edit_creditcard_overlay.js
index 3a77590555a4086feba72c6b6b3857f07479fa85..0fc02d53fac6a88b4dc05a3e64eb69a161868f1d 100644
--- a/chrome/browser/resources/options/autofill_edit_creditcard_overlay.js
+++ b/chrome/browser/resources/options/autofill_edit_creditcard_overlay.js
@@ -117,7 +117,7 @@ cr.define('options', function() {
text = i;
var option = document.createElement('option');
- option.text = text;
+ option.text = String(text);
option.value = text;
Dan Beam 2014/09/11 02:53:08 option.text = options.value = text;
Vitaly Pavlenko 2014/09/11 04:16:24 Done.
expirationMonth.add(option, null);
}
@@ -131,7 +131,7 @@ cr.define('options', function() {
for (var i = 0; i < 10; ++i) {
var text = year + i;
var option = document.createElement('option');
- option.text = text;
+ option.text = String(text);
option.value = text;
expirationYear.add(option, null);
}
@@ -153,6 +153,7 @@ cr.define('options', function() {
/**
* Sets the value of each input field according to |creditCard|
+ * @param {CreditCardData} creditCard
* @private
*/
setInputFields_: function(creditCard) {
@@ -168,7 +169,7 @@ cr.define('options', function() {
var idx = parseInt(creditCard.expirationMonth, 10);
$('expiration-month').selectedIndex = idx - 1;
- expYear = creditCard.expirationYear;
+ var expYear = creditCard.expirationYear;
var date = new Date();
var year = parseInt(date.getFullYear(), 10);
for (var i = 0; i < 10; ++i) {
@@ -190,6 +191,7 @@ cr.define('options', function() {
/**
* Loads the credit card data from |creditCard|, sets the input fields based
* on this data and stores the GUID of the credit card.
+ * @param {CreditCardData} creditCard
* @private
*/
loadCreditCard_: function(creditCard) {

Powered by Google App Engine
This is Rietveld 408576698