mirror of
https://framagit.org/hubzilla/core.git
synced 2026-06-21 00:52:33 -04:00
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:
@@ -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) {
|
||||
|
||||
Reference in New Issue
Block a user