Skip to content

Commit a3a3415

Browse files
committed
lint
1 parent b61d33e commit a3a3415

File tree

2 files changed

+5
-9
lines changed

2 files changed

+5
-9
lines changed

lib/shadow/npm-injection.cjs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -484,14 +484,14 @@ function walk (diff, needInfoOn = []) {
484484

485485
/**
486486
* @param {SafeArborist} safeArb
487-
* @param {string} registry
487+
* @param {string} _registry
488488
* @param {InstallEffect[]} pkgs
489489
* @param {import('ora')['default'] | null} ora
490-
* @param {Readable | null} [input]
490+
* @param {Readable | null} [_input]
491491
* @param {Writable | null} [output]
492492
* @returns {Promise<boolean>}
493493
*/
494-
async function packagesHaveRiskyIssues (safeArb, registry, pkgs, ora = null, input, output) {
494+
async function packagesHaveRiskyIssues (safeArb, _registry, pkgs, ora = null, _input, output) {
495495
let failed = false
496496
if (pkgs.length) {
497497
let remaining = pkgs.length

lib/shadow/tty-server.cjs

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -158,12 +158,8 @@ module.exports = async function createTTYServer (colorLevel, isInteractive, npml
158158
npmlog.resume()
159159
nextCapture()
160160
})
161-
}).listen(sock, /** @type {(err: Error) => void} */ (err) => {
162-
if (err) {
163-
reject(err)
164-
} else {
165-
resolve(server)
166-
}
161+
}).listen(sock, () => resolve(server)).on('error', (err) => {
162+
reject(err)
167163
}).unref()
168164
process.on('exit', () => {
169165
server.close()

0 commit comments

Comments
 (0)