fix breakage due to URI.js upgrade
This commit is contained in:
parent
5b43bd857c
commit
61558e00ae
@ -44,10 +44,10 @@ export function amountToPretty(amount: AmountJson): string {
|
||||
* See http://api.taler.net/wallet.html#general
|
||||
*/
|
||||
export function canonicalizeBaseUrl(url: string) {
|
||||
const x = new URI(url);
|
||||
if (!x.protocol()) {
|
||||
x.protocol("https");
|
||||
if (!url.startsWith("http") && !url.startsWith("https")) {
|
||||
url = "https://" + url;
|
||||
}
|
||||
const x = new URI(url);
|
||||
x.path(x.path() + "/").normalizePath();
|
||||
x.fragment("");
|
||||
x.query();
|
||||
|
Loading…
Reference in New Issue
Block a user