mirror of https://github.com/calzoneman/sync.git
Fix a few things
This commit is contained in:
parent
fd328d443d
commit
0dfb6df8a7
|
@ -445,6 +445,9 @@ Callbacks = {
|
|||
|
||||
if (!CLIENT.guest) {
|
||||
socket.emit("initUserPLCallbacks");
|
||||
if ($("#loginform").length === 0) {
|
||||
return;
|
||||
}
|
||||
var logoutform = $("<p/>").attr("id", "logoutform")
|
||||
.addClass("navbar-text pull-right")
|
||||
.insertAfter($("#loginform"));
|
||||
|
@ -1151,7 +1154,7 @@ try {
|
|||
}
|
||||
}
|
||||
if (ALLOW_SSL && (location.protocol === "https:" || USEROPTS.secure_connection)) {
|
||||
socket = io.connect(IO_URL, opts);
|
||||
socket = io.connect(IO_URL, { secure: true });
|
||||
} else {
|
||||
socket = io.connect(IO_URL);
|
||||
}
|
||||
|
|
|
@ -11,6 +11,10 @@
|
|||
}
|
||||
}
|
||||
|
||||
if (theme == null || !theme.match(/^\/css\/themes\/\w+.css$/)) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (theme !== "/css/themes/slate.css") {
|
||||
console.log("THEME COOKIE:", theme);
|
||||
var cur = document.getElementById("usertheme");
|
||||
|
|
|
@ -864,14 +864,16 @@ function handleModPermissions() {
|
|||
$("#cs-jstext").val(CHANNEL.js);
|
||||
$("#cs-motdtext").val(CHANNEL.motd_text);
|
||||
setParentVisible("a[href='#cs-motdeditor']", hasPermission("motdedit"));
|
||||
setParentVisible("a[href='#cs-permissions']", CLIENT.rank >= 3);
|
||||
setParentVisible("a[href='#cs-permedit']", CLIENT.rank >= 3);
|
||||
setParentVisible("a[href='#cs-banlist']", hasPermission("ban"));
|
||||
setParentVisible("a[href='#cs-csseditor']", CLIENT.rank >= 3);
|
||||
setParentVisible("a[href='#cs-jseditor']", CLIENT.rank >= 3);
|
||||
setParentVisible("a[href='#cs-filtereditor']", CLIENT.rank >= 3);
|
||||
setParentVisible("a[href='#cs-chatfilters']", hasPermission("filteredit"));
|
||||
setParentVisible("a[href='#cs-emotes']", hasPermission("emoteedit"));
|
||||
setParentVisible("a[href='#cs-chanranks']", CLIENT.rank >= 3);
|
||||
setParentVisible("a[href='#cs-chanlog']", CLIENT.rank >= 3);
|
||||
$("#cs-chatfilters-import").attr("disabled", !hasPermission("filterimport"));
|
||||
$("#cs-emotes-import").attr("disabled", !hasPermission("filterimport"));
|
||||
}
|
||||
|
||||
function handlePermissionChange() {
|
||||
|
|
Loading…
Reference in New Issue