Skip to content

Commit

Permalink
fix(loader): fix filename slash on windows, close #875
Browse files Browse the repository at this point in the history
  • Loading branch information
shigma committed Dec 11, 2022
1 parent 0acae29 commit 022de8e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/loader/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@koishijs/loader",
"description": "Config Loader for Koishi",
"version": "2.2.4",
"version": "2.2.5",
"main": "lib/node.js",
"typings": "lib/index.d.ts",
"exports": {
Expand Down Expand Up @@ -41,7 +41,7 @@
"koishi": "^4.10.5"
},
"devDependencies": {
"@koishijs/registry": "^4.1.5",
"@koishijs/registry": "^4.1.7",
"@types/js-yaml": "^4.0.5",
"koishi": "^4.10.5"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/loader/src/node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export default class NodeLoader extends Loader {
for (const extname of supportedExts) {
if (files.includes(basename + extname)) {
this.extname = extname
this.filename = this.baseDir + '/' + basename + extname
this.filename = resolve(this.baseDir, basename + extname)
return
}
}
Expand Down

0 comments on commit 022de8e

Please sign in to comment.