Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/dotnet/aspnetcore.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKuinox <github@kuinox.io>2022-11-10 02:02:29 +0300
committerGitHub <noreply@github.com>2022-11-10 02:02:29 +0300
commitbb6a05b71bb1b50fc561522ac9284ca88580b65b (patch)
tree3f5bb2f5fe98463ce64e4bf1762eb82fd545b3cf
parent5e98069161bc7c860e6452055509150129441928 (diff)
Fixed a concatenation issue in special URIs. (#44968)
-rw-r--r--src/JSInterop/Microsoft.JSInterop.JS/src/src/Microsoft.JSInterop.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/JSInterop/Microsoft.JSInterop.JS/src/src/Microsoft.JSInterop.ts b/src/JSInterop/Microsoft.JSInterop.JS/src/src/Microsoft.JSInterop.ts
index 46676d0d6f..7e507b79dc 100644
--- a/src/JSInterop/Microsoft.JSInterop.JS/src/src/Microsoft.JSInterop.ts
+++ b/src/JSInterop/Microsoft.JSInterop.JS/src/src/Microsoft.JSInterop.ts
@@ -71,7 +71,7 @@ export module DotNet {
// However since we're the one calling the import keyword, they would be resolved relative to
// this framework bundle URL. Fix this by providing an absolute URL.
if (typeof url === "string" && url.startsWith("./")) {
- url = document.baseURI + url.substr(2);
+ url = new URL(url.substr(2), document.baseURI).toString();
}
return import(/* webpackIgnore: true */ url);