Skip to content

Commit 1abbe96

Browse files
committed
[ADD] path checks for a few javascript files where it was missing
1 parent b47051b commit 1abbe96

File tree

5 files changed

+7
-7
lines changed

5 files changed

+7
-7
lines changed
10 Bytes
Binary file not shown.

html/assets/js/change_toggle_option.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@
66
*/
77

88
function change_toggle_option(url) {
9-
window.location.pathname = url;
9+
window.location.pathname = checkHtmlPath() + url;
1010
}

html/assets/js/login/log_user_in.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ async function log_user_in() {
2828
if (response.ok) {
2929
console.log("Login successful:", response);
3030
// window.location.pathname = window.constants.dashboard_page;
31-
window.location.pathname = dashboard;
31+
window.location.pathname = checkHtmlPath() + dashboard;
3232
} else {
3333
update_error_message("Login failed: " + response.message);
3434
}
@@ -49,7 +49,7 @@ async function log_user_in_professional() {
4949
if (response.ok) {
5050
console.log("Login successful:", response);
5151
// window.location.pathname = window.constants.dashboard_page;
52-
window.location.pathname = suivi;
52+
window.location.pathname = checkHtmlPath() + suivi;
5353
} else {
5454
update_error_message("Login failed: " + response.message);
5555
}

html/assets/js/login/register_user.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ async function register_user() {
3737
if (response.ok) {
3838
console.log("Registration successful:", response);
3939
// window.location.pathname = window.constants.dashboard_page;
40-
window.location.pathname = dashboard;
40+
window.location.pathname = checkHtmlPath() + dashboard;
4141
} else {
4242
update_error_message("Registration failed: " + response.message);
4343
}
@@ -66,7 +66,7 @@ async function register_user_professional() {
6666
if (response.ok) {
6767
console.log("Registration successful:", response);
6868
// window.location.pathname = window.constants.dashboard_page;
69-
window.location.pathname = suivi;
69+
window.location.pathname = checkHtmlPath() + suivi;
7070
} else {
7171
update_error_message("Registration failed: " + response.message);
7272
}

html/assets/js/password/get_sso_details.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@ async function get_sso_details() {
2020
if (response.ok) {
2121
console.log("Registration successful:", response);
2222
window.cookie_manager.create(user_username_cookie_name, username);
23-
window.location.pathname = window.constants.dashboard_page;
23+
window.location.pathname = checkHtmlPath() + window.constants.dashboard_page;
2424
} else {
2525
update_error_message("Registration failed: " + response.message);
26-
window.location.pathname = window.constants.home_page;
26+
window.location.pathname = checkHtmlPath() + window.constants.home_page;
2727
}
2828
};
2929

0 commit comments

Comments
 (0)