mirror of
https://github.com/GCMatters/hermes.git
synced 2026-02-04 13:40:13 +01:00
fix: fix acces for logged out visitors
This commit is contained in:
@@ -13,17 +13,19 @@ const urlParams = new URLSearchParams(queryString);
|
||||
const eventId = urlParams.get('event');
|
||||
document.addEventListener("DOMContentLoaded", () => __awaiter(void 0, void 0, void 0, function* () {
|
||||
var container = document.getElementById("mainContainer");
|
||||
var user = yield getMyAccount();
|
||||
var org_id = -1;
|
||||
const modifyBtn = document.getElementById("editBtn");
|
||||
const removeBtn = document.getElementById("removeBtn");
|
||||
if (user) {
|
||||
if (user.isOrganisation) {
|
||||
org_id = user.organisationId;
|
||||
var org_id = -1;
|
||||
try {
|
||||
var user = yield getMyAccount();
|
||||
if (user) {
|
||||
if (user.isOrganisation) {
|
||||
org_id = user.organisationId;
|
||||
}
|
||||
unhideElementById(document, "logout-btn");
|
||||
}
|
||||
unhideElementById(document, "logout-btn");
|
||||
}
|
||||
else {
|
||||
catch (_a) {
|
||||
unhideElementById(document, "joinnow-btn");
|
||||
unhideElementById(document, "signin-btn");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user