More IE 11 hacks

This commit is contained in:
Nikita Karamov 2020-09-23 18:32:36 +02:00
parent ee1089ef65
commit 2bc5833fca
No known key found for this signature in database
GPG Key ID: E40DFE6E993540FF
1 changed files with 2 additions and 3 deletions

View File

@ -26,11 +26,10 @@ document
var instance = e.target.elements['instance'].value;
var remember = e.target.elements['remember'].checked;
if (!(instance.startsWith("https://") || instance.startsWith("http://"))) {
if (instance.indexOf("http://") == -1 && instance.indexOf("https://") == -1) {
instance = "https://" + instance;
}
if (!instance.endsWith("/")){
if (instance.charAt(instance.length - 1) !== '/'){
instance = instance + "/";
}