save register cache on tick instead of sigint - fixes #1062
This commit is contained in:
parent
bc6d01d6fc
commit
5c41a33e41
@ -13,14 +13,7 @@ export function load() {
|
||||
if (process.env.BABEL_DISABLE_CACHE) return;
|
||||
|
||||
process.on("exit", save);
|
||||
|
||||
var sigint = function () {
|
||||
process.removeListener("SIGINT", sigint);
|
||||
save();
|
||||
process.kill(process.pid, "SIGINT");
|
||||
};
|
||||
|
||||
process.on("SIGINT", sigint);
|
||||
process.nextTick(save);
|
||||
|
||||
if (!fs.existsSync(FILENAME)) return;
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user