Skip to content

Commit

Permalink
[Refactor] no-extraneous-dependencies: use Array.isArray instead …
Browse files Browse the repository at this point in the history
…of lodash
  • Loading branch information
ljharb committed Jul 17, 2019
1 parent c5078ad commit 8a38fd4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/rules/no-extraneous-dependencies.js
@@ -1,6 +1,6 @@
import path from 'path'
import fs from 'fs'
import { isArray, isEmpty } from 'lodash'
import { isEmpty } from 'lodash'
import readPkgUp from 'read-pkg-up'
import minimatch from 'minimatch'
import resolve from 'eslint-module-utils/resolve'
Expand Down Expand Up @@ -32,7 +32,7 @@ function getDependencies(context, packageDir) {
}

if (!isEmpty(packageDir)) {
if (!isArray(packageDir)) {
if (!Array.isArray(packageDir)) {
paths = [path.resolve(packageDir)]
} else {
paths = packageDir.map(dir => path.resolve(dir))
Expand Down

0 comments on commit 8a38fd4

Please sign in to comment.