Skip to content

Commit c69d9b2

Browse files
authored
fixed a few lint errros (#111)
1 parent 6acb230 commit c69d9b2

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

src/cli/commands/cache.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@ import type Config from "../../config.js";
1414
import { MessageError } from "../../errors.js";
1515
import * as fs from "../../util/fs.js";
1616

17-
let path = require("path");
18-
1917
export function setFlags(commander: Object) {
2018
commander.usage("cache [clear | ls]");
2119
}
@@ -39,7 +37,7 @@ export async function run(
3937
throw new MessageError("TODO");
4038
}
4139

42-
if (cmd === "clear") {
40+
if (cmd === "clear" && config.packagesRoot) {
4341
await fs.unlink(config.packagesRoot);
4442
reporter.success(`Cleared ${config.packagesRoot}`);
4543
}

src/util/child.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
import * as constants from "../constants.js";
1414
import BlockingQueue from "./blocking-queue.js";
1515
import { promisify } from "./promise.js";
16+
import { MessageError } from "../errors.js";
1617

1718
let child = require("child_process");
1819

0 commit comments

Comments
 (0)