Index: chrome/browser/resources/options/browser_options.js |
diff --git a/chrome/browser/resources/options/browser_options.js b/chrome/browser/resources/options/browser_options.js |
index b3ca550e5fb157900f779676a17230ce42647273..aed0a43bd0afcdc70c787ca2b9785427a17c0025 100644 |
--- a/chrome/browser/resources/options/browser_options.js |
+++ b/chrome/browser/resources/options/browser_options.js |
@@ -651,7 +651,8 @@ cr.define('options', function() { |
true); |
document.body.addEventListener('click', function(e) { |
Dan Beam
2014/09/12 03:25:19
var target = assertInstanceof(e.target, Node);
Vitaly Pavlenko
2014/09/12 19:16:22
Done.
|
- var button = findAncestor(e.target, function(el) { |
+ var button = findAncestor(assertInstanceof(e.target, Node), |
+ function(el) { |
return el.tagName == 'BUTTON' && |
el.dataset.extensionId !== undefined && |
el.dataset.extensionId.length; |
@@ -707,7 +708,7 @@ cr.define('options', function() { |
* @private |
*/ |
handleWindowMessage_: function(e) { |
- if (e.data.method == 'frameSelected') |
+ if ((/** @type {{method: string}} */(e.data)).method == 'frameSelected') |
$('search-field').focus(); |
}, |
@@ -1241,7 +1242,8 @@ cr.define('options', function() { |
/** |
* Get the selected profile item from the profile list. This also works |
* correctly if the list is not displayed. |
- * @return {Object} the profile item object, or null if nothing is selected. |
+ * @return {?Object} The profile item object, or null if nothing is |
+ * selected. |
* @private |
*/ |
getSelectedProfileItem_: function() { |