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

Unified Diff: tracing/tracing/ui/base/grouping_table.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/file.html ('k') | tracing/tracing/ui/base/heading.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tracing/tracing/ui/base/grouping_table.html
diff --git a/tracing/tracing/ui/base/grouping_table.html b/tracing/tracing/ui/base/grouping_table.html
index 4a7e11e68358d2fe1820fb8aa84136983e673055..4b24c828a0fe68100d8fdfd6ba232602851c262e 100644
--- a/tracing/tracing/ui/base/grouping_table.html
+++ b/tracing/tracing/ui/base/grouping_table.html
@@ -28,8 +28,9 @@ tr.exportTo('tr.ui.b', function() {
function Row(title, data, groupingKeyFuncs, rowStatsConstructor) {
this.title = title;
this.data_ = data;
- if (groupingKeyFuncs === undefined)
+ if (groupingKeyFuncs === undefined) {
groupingKeyFuncs = [];
+ }
this.groupingKeyFuncs_ = groupingKeyFuncs;
this.rowStatsConstructor_ = rowStatsConstructor;
@@ -41,8 +42,7 @@ tr.exportTo('tr.ui.b', function() {
Row.prototype = {
getCurrentGroupingKeyFunc_: function() {
- if (this.groupingKeyFuncs_.length === 0)
- return undefined;
+ if (this.groupingKeyFuncs_.length === 0) return undefined;
return this.groupingKeyFuncs_[0];
},
@@ -58,8 +58,7 @@ tr.exportTo('tr.ui.b', function() {
},
rebuildSubRowsIfNeeded_: function() {
- if (this.subRowsBuilt_)
- return;
+ if (this.subRowsBuilt_) return;
this.subRowsBuilt_ = true;
var groupingKeyFunc = this.getCurrentGroupingKeyFunc_();
@@ -73,8 +72,9 @@ tr.exportTo('tr.ui.b', function() {
this.data_.forEach(function(datum) {
var key = groupingKeyFunc(datum);
hasValues = hasValues || (key !== undefined);
- if (dataByKey[key] === undefined)
+ if (dataByKey[key] === undefined) {
dataByKey[key] = [];
+ }
dataByKey[key].push(datum);
});
if (!hasValues) {
« no previous file with comments | « tracing/tracing/ui/base/file.html ('k') | tracing/tracing/ui/base/heading.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698