From 23e278da623200d9f7f1228246fed63897695844 Mon Sep 17 00:00:00 2001 From: Stephen Whitmore Date: Thu, 5 Oct 2017 16:28:47 -0700 Subject: [PATCH] fix: fallback cache dir guess --- local-cache.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/local-cache.js b/local-cache.js index 32fff4f..09f3d42 100644 --- a/local-cache.js +++ b/local-cache.js @@ -2,7 +2,7 @@ var fs = require('fs') var path = require('path') var debug = require('debug')('friendpm') -var CACHE_DIR = process.env.npm_config_cache +var CACHE_DIR = process.env.npm_config_cache || path.join(require('os').homedir(), '.npm') module.exports = function (opts) { var reg = {}