make sure to only call init_contact_edit() on pageload if we have a fragment and are in /connections. this is to prevent fragment hijacking for other pages

This commit is contained in:
Mario
2025-10-30 21:37:41 +00:00
parent 5b6d70fd60
commit ef05cecaeb

View File

@@ -30,17 +30,17 @@
let sub_section;
$(document).ready(function() {
if (window.location.hash) {
let path_parts = window.location.pathname.split('/').filter(Boolean);
if (window.location.hash && path_parts[0] === 'connections') {
poi = window.location.hash.substr(1);
init_contact_edit(poi);
}
window.onhashchange = function() {
if (window.location.hash) {
window.onhashchange = function() {
poi = window.location.hash.substr(1);
init_contact_edit(poi);
}
};
};
}
});
$(document).on('click', '.contact-edit', function (e) {