Update static/js/home.js
Browse files- static/js/home.js +5 -3
static/js/home.js
CHANGED
@@ -2,7 +2,7 @@ const getLocalUser = localStorage.getItem("username");
|
|
2 |
if (getLocalUser) {
|
3 |
document.getElementById("userProfile").innerHTML = `${getLocalUser}`;
|
4 |
} else {
|
5 |
-
document.getElementById("userProfile").innerHTML = "
|
6 |
}
|
7 |
|
8 |
function populateYearDropdown(startYear, endYear) {
|
@@ -1018,7 +1018,8 @@ else if (selectedFeature.feature === 'venues') {
|
|
1018 |
return response.json();
|
1019 |
}
|
1020 |
} ).then(data1 =>{
|
1021 |
-
|
|
|
1022 |
method: 'GET',
|
1023 |
});
|
1024 |
} )
|
@@ -1066,7 +1067,8 @@ else if (selectedFeature.feature === 'venues') {
|
|
1066 |
return response.json();
|
1067 |
}
|
1068 |
} ).then(data1 =>{
|
1069 |
-
|
|
|
1070 |
method: 'GET',
|
1071 |
});
|
1072 |
} )
|
|
|
2 |
if (getLocalUser) {
|
3 |
document.getElementById("userProfile").innerHTML = `${getLocalUser}`;
|
4 |
} else {
|
5 |
+
document.getElementById("userProfile").innerHTML = "User";
|
6 |
}
|
7 |
|
8 |
function populateYearDropdown(startYear, endYear) {
|
|
|
1018 |
return response.json();
|
1019 |
}
|
1020 |
} ).then(data1 =>{
|
1021 |
+
let secureUrl = data1.open_url.replace(/^https?:/, window.location.protocol);
|
1022 |
+
fetch(secureUrl, {
|
1023 |
method: 'GET',
|
1024 |
});
|
1025 |
} )
|
|
|
1067 |
return response.json();
|
1068 |
}
|
1069 |
} ).then(data1 =>{
|
1070 |
+
let secureUrl = data1.open_url.replace(/^https?:/, window.location.protocol);
|
1071 |
+
fetch(secureUrl, {
|
1072 |
method: 'GET',
|
1073 |
});
|
1074 |
} )
|