Commit 844b6d3b authored by alexpott's avatar alexpott

Issue #2914716 by droplet: JS codestyle: no-lonely-if

parent 336d30dc
......@@ -10,7 +10,6 @@
"no-new": "off",
"no-multi-assign": "off",
"no-mixed-operators": "off",
"no-lonely-if": "off",
"no-empty": "off",
"no-continue": "off",
"new-cap": "off",
......
......@@ -892,11 +892,9 @@
}
}
}
else {
// Do not allow a row to be swapped with itself.
if (row === this.rowObject.element) {
return null;
}
// Do not allow a row to be swapped with itself.
else if (row === this.rowObject.element) {
return null;
}
// Check that swapping with this row is allowed.
......
......@@ -554,11 +554,9 @@
return null;
}
}
} else {
if (row === this.rowObject.element) {
} else if (row === this.rowObject.element) {
return null;
}
}
if (!this.rowObject.isValidSwap(row)) {
return null;
......
......@@ -231,11 +231,9 @@
if (context && context.reason === 'mouseleave') {
accept = false;
}
else {
// Check whether the transition has been confirmed?
if (context && context.confirmed) {
accept = true;
}
// Check whether the transition has been confirmed?
else if (context && context.confirmed) {
accept = true;
}
}
}
......
......@@ -121,11 +121,9 @@
} else if ((from === 'changed' || from === 'invalid') && to === 'candidate') {
if (context && context.reason === 'mouseleave') {
accept = false;
} else {
if (context && context.confirmed) {
} else if (context && context.confirmed) {
accept = true;
}
}
}
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment