Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorisaacs <i@izs.me>2020-07-23 23:28:00 +0300
committerisaacs <i@izs.me>2020-07-29 21:54:59 +0300
commit8654c05e6e8cabf4642425b9e6373aeae9801c21 (patch)
treea8a5053204d15c5eff467a90175526eba6233999 /lib/fund.js
parentc3b3b79b03583887ba8e63201c1a01e8043a89e9 (diff)
lint the lib folder
Diffstat (limited to 'lib/fund.js')
-rw-r--r--lib/fund.js6
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/fund.js b/lib/fund.js
index 660e22468..fdd1bd07a 100644
--- a/lib/fund.js
+++ b/lib/fund.js
@@ -80,8 +80,7 @@ function printHuman (fundingInfo, { unicode }) {
// puts child nodes back into returned archy
// output while also filtering out missing items
leave: (item, children) => {
- if (item)
- item.nodes = children.filter(Boolean)
+ if (item) { item.nodes = children.filter(Boolean) }
return item
},
@@ -102,7 +101,6 @@ function printHuman (fundingInfo, { unicode }) {
async function openFundingUrl ({ path, tree, spec, fundingSourceNumber }) {
const arg = npa(spec, path)
const retrievePackageMetadata = () => {
-
if (arg.type === 'directory') {
if (tree.path === arg.fetchSpec) {
// matches cwd, e.g: npm fund .
@@ -118,7 +116,7 @@ async function openFundingUrl ({ path, tree, spec, fundingSourceNumber }) {
} else {
// tries to retrieve a package from arborist inventory
// by matching resulted package name from the provided spec
- const [ item ] = [...tree.inventory.query('name', arg.name)]
+ const [item] = [...tree.inventory.query('name', arg.name)]
.filter(i => semver.valid(i.package.version))
.sort((a, b) => semver.rcompare(a.package.version, b.package.version))