projects
/
dotfiles
/
.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Giant blob of minor changes
[dotfiles/.git]
/
.config
/
coc
/
extensions
/
node_modules
/
coc-prettier
/
node_modules
/
import-fresh
/
index.js
diff --git
a/.config/coc/extensions/node_modules/coc-prettier/node_modules/import-fresh/index.js
b/.config/coc/extensions/node_modules/coc-prettier/node_modules/import-fresh/index.js
index 425ed98c42f68ebb48e2b9d2622109c9f360a861..0a4c5d52f6d32274d3032c2c7cf513ac8d1a81af 100644
(file)
--- a/
.config/coc/extensions/node_modules/coc-prettier/node_modules/import-fresh/index.js
+++ b/
.config/coc/extensions/node_modules/coc-prettier/node_modules/import-fresh/index.js
@@
-10,7
+10,8
@@
module.exports = moduleId => {
const parentPath = parentModule(__filename);
const parentPath = parentModule(__filename);
- const filePath = resolveFrom(path.dirname(parentPath), moduleId);
+ const cwd = parentPath ? path.dirname(parentPath) : __dirname;
+ const filePath = resolveFrom(cwd, moduleId);
const oldModule = require.cache[filePath];
// Delete itself from module parent
const oldModule = require.cache[filePath];
// Delete itself from module parent