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:
Joel McKinnon
2020-08-10 11:23:35 -07:00
committed by GitHub
parent ef965ebdfd
commit 4d560086dd
119 changed files with 194 additions and 225 deletions

View File

@@ -213,9 +213,9 @@ export default {
this.enumerations = foundMetadata.enumerations;
} else if (foundMetadata.format === 'string' || foundMetadata.format === 'number') {
this.operationFormat = foundMetadata.format;
} else if (foundMetadata.hints.hasOwnProperty('range')) {
} else if (Object.prototype.hasOwnProperty.call(foundMetadata.hints, 'range')) {
this.operationFormat = 'number';
} else if (foundMetadata.hints.hasOwnProperty('domain')) {
} else if (Object.prototype.hasOwnProperty.call(foundMetadata.hints, 'domain')) {
this.operationFormat = 'number';
} else if (foundMetadata.key === 'name') {
this.operationFormat = 'string';