mirror of
https://github.com/dillonkearns/elm-pages-v3-beta.git
synced 2024-12-23 11:55:41 +03:00
Prevent duplicate leading file path by using resolve instead of prepending cwd.
This commit is contained in:
parent
6850d98562
commit
4d0f9a8708
@ -59,7 +59,7 @@ function lookupOrPerform(portsFile, mode, rawRequest, hasFsAccess) {
|
||||
if (portsFile === undefined) {
|
||||
throw "missing"
|
||||
}
|
||||
const portDataSourcePath = path.join(process.cwd(), portsFile);
|
||||
const portDataSourcePath = path.resolve(portsFile);
|
||||
// On Windows, we need cannot use paths directly and instead must use a file:// URL.
|
||||
portDataSource = await import(url.pathToFileURL(portDataSourcePath).href);
|
||||
} catch (e) {
|
||||
|
Loading…
Reference in New Issue
Block a user