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

Unified Diff: tracing/tracing/ui/base/hot_key.html

Issue 2776653002: [ESLint] Fix violations when enabling curly rule in eslint. (Closed)
Patch Set: rebase Created 3 years, 9 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
« no previous file with comments | « tracing/tracing/ui/base/heading.html ('k') | tracing/tracing/ui/base/hotkey_controller.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tracing/tracing/ui/base/hot_key.html
diff --git a/tracing/tracing/ui/base/hot_key.html b/tracing/tracing/ui/base/hot_key.html
index aa2498cd53c89a3b263d41aefe42f6d4191f019e..00e790397edd13d9b6ab087a322a471ad9ffb98c 100644
--- a/tracing/tracing/ui/base/hot_key.html
+++ b/tracing/tracing/ui/base/hot_key.html
@@ -10,21 +10,25 @@ found in the LICENSE file.
tr.exportTo('tr.ui.b', function() {
function HotKey(dict) {
- if (dict.eventType === undefined)
+ if (dict.eventType === undefined) {
throw new Error('eventType must be given');
- if (dict.keyCode === undefined && dict.keyCodes === undefined)
+ }
+ if (dict.keyCode === undefined && dict.keyCodes === undefined) {
throw new Error('keyCode or keyCodes must be given');
- if (dict.keyCode !== undefined && dict.keyCodes !== undefined)
+ }
+ if (dict.keyCode !== undefined && dict.keyCodes !== undefined) {
throw new Error('Only keyCode or keyCodes can be given');
- if (dict.callback === undefined)
+ }
+ if (dict.callback === undefined) {
throw new Error('callback must be given');
+ }
this.eventType_ = dict.eventType;
this.keyCodes_ = [];
- if (dict.keyCode)
+ if (dict.keyCode) {
this.pushKeyCode_(dict.keyCode);
- else if (dict.keyCodes) {
+ } else if (dict.keyCodes) {
dict.keyCodes.forEach(this.pushKeyCode_, this);
}
« no previous file with comments | « tracing/tracing/ui/base/heading.html ('k') | tracing/tracing/ui/base/hotkey_controller.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698