1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-09-14 02:08:50 +02:00

only perpend http if there is no protocol

This commit is contained in:
Kyle Spearrin 2018-03-05 22:15:22 -05:00
parent cca9c3c561
commit 859f44db43

View File

@ -191,7 +191,7 @@
function fixUri(uri) {
uri = uri.toLowerCase().trim();
if (!uri.startsWith('http') && uri.indexOf('.') >= 0) {
if (uri.indexOf('://') === -1 && uri.indexOf('.') >= 0) {
uri = 'http://' + uri;
}