mirror of
https://github.com/bitwarden/browser
synced 2025-12-16 08:13:42 +00:00
add http protocol if none fiven
This commit is contained in:
@@ -151,6 +151,10 @@ export class UtilsService implements UtilsServiceAbstraction {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (uriString.indexOf('://') === -1) {
|
||||||
|
uriString = 'http://' + uriString;
|
||||||
|
}
|
||||||
|
|
||||||
if (uriString.startsWith('http://') || uriString.startsWith('https://')) {
|
if (uriString.startsWith('http://') || uriString.startsWith('https://')) {
|
||||||
try {
|
try {
|
||||||
return new URL(uriString);
|
return new URL(uriString);
|
||||||
|
|||||||
Reference in New Issue
Block a user