mirror of
https://github.com/nasa/openmct.git
synced 2025-05-06 10:38:23 +00:00
[Style] Fix style
This commit is contained in:
parent
e2f9a0c9cd
commit
6e4abcfed8
@ -22,6 +22,10 @@
|
|||||||
|
|
||||||
define([], function () {
|
define([], function () {
|
||||||
|
|
||||||
|
function isTruthy(a) {
|
||||||
|
return !!a;
|
||||||
|
}
|
||||||
|
|
||||||
function validateMenuOption(menuOption, index) {
|
function validateMenuOption(menuOption, index) {
|
||||||
if (menuOption.clock && !menuOption.clockOffsets) {
|
if (menuOption.clock && !menuOption.clockOffsets) {
|
||||||
return "clock-based menuOption at index " + index + " is " +
|
return "clock-based menuOption at index " + index + " is " +
|
||||||
@ -45,7 +49,7 @@ define([], function () {
|
|||||||
}
|
}
|
||||||
if (config.menuOptions.some(validateMenuOption)) {
|
if (config.menuOptions.some(validateMenuOption)) {
|
||||||
return config.menuOptions.map(validateMenuOption)
|
return config.menuOptions.map(validateMenuOption)
|
||||||
.filter(function (err) { return !!err; })
|
.filter(isTruthy)
|
||||||
.join('\n');
|
.join('\n');
|
||||||
}
|
}
|
||||||
return undefined;
|
return undefined;
|
||||||
@ -69,11 +73,11 @@ define([], function () {
|
|||||||
"timeSystem that does not exist: " + menuOption.timeSystem;
|
"timeSystem that does not exist: " + menuOption.timeSystem;
|
||||||
}
|
}
|
||||||
if (menuOption.clock && !clocks[menuOption.clock]) {
|
if (menuOption.clock && !clocks[menuOption.clock]) {
|
||||||
return "menuOption at index " + index + " specifies a " +
|
return "menuOption at index " + index + " specifies a " +
|
||||||
"clock that does not exist: " + menuOption.clock;
|
"clock that does not exist: " + menuOption.clock;
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.filter(function (err) { return !!err; })
|
.filter(isTruthy)
|
||||||
.join('\n');
|
.join('\n');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user