From f0ac6990ec206d9259e6f1b1e261af9d64e34196 Mon Sep 17 00:00:00 2001 From: ehmicky Date: Sun, 20 Dec 2020 09:54:32 +0100 Subject: [PATCH] chore: enable `fp/no-class` ESLint rule (#251) --- .eslintrc.js | 2 -- src/index.js | 3 +++ 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index 48bf5ca..4f6d90c 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -6,11 +6,9 @@ module.exports = { // TODO: enable those rules complexity: 0, 'max-statements': 0, - 'fp/no-class': 0, 'fp/no-let': 0, 'fp/no-loops': 0, 'fp/no-mutation': 0, - 'fp/no-this': 0, 'promise/no-callback-in-promise': 0, 'promise/prefer-await-to-callbacks': 0, }, diff --git a/src/index.js b/src/index.js index 167c389..77822a4 100644 --- a/src/index.js +++ b/src/index.js @@ -5,6 +5,8 @@ const deploy = require('./deploy') const { getMethods } = require('./methods') const { getOperations } = require('./operations') +/* eslint-disable fp/no-this */ +// eslint-disable-next-line fp/no-class class NetlifyAPI { constructor(firstArg, secondArg) { // variadic arguments @@ -89,6 +91,7 @@ class NetlifyAPI { return await deploy(this, siteId, buildDir, opts) } } +/* eslint-enable fp/no-this */ const getBasePath = function ({ scheme, host, pathPrefix }) { return `${scheme}://${host}${pathPrefix}`