mirror of
https://github.com/nasa/openmct.git
synced 2025-06-23 01:18:57 +00:00
ESLint upgrade, implement additional rules (#3230)
* upgrade to ESLintv7, added overrides for rules violated * removed overrides for spec files * fixed no-prototype-builtins issues * added rules for default-case-last, default-param-last, grouped-accessor-pairs, no-constructor-return, and added override for one violation Co-authored-by: Andrew Henry <akhenry@gmail.com> Co-authored-by: Shefali Joshi <simplyrender@gmail.com>
This commit is contained in:
@ -63,7 +63,7 @@ define([
|
||||
byString: {}
|
||||
});
|
||||
this.formatter.format = function (value) {
|
||||
if (this.enumerations.byValue.hasOwnProperty(value)) {
|
||||
if (Object.prototype.hasOwnProperty.call(this.enumerations.byValue, value)) {
|
||||
return this.enumerations.byValue[value];
|
||||
}
|
||||
|
||||
@ -71,7 +71,7 @@ define([
|
||||
}.bind(this);
|
||||
this.formatter.parse = function (string) {
|
||||
if (typeof string === "string") {
|
||||
if (this.enumerations.byString.hasOwnProperty(string)) {
|
||||
if (Object.prototype.hasOwnProperty.call(this.enumerations.byString, string)) {
|
||||
return this.enumerations.byString[string];
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user