Add ACL check so moderators can toggle jukebox

This commit is contained in:
Salanto 2021-09-12 23:49:20 +02:00
parent 8bdfe1e045
commit 00da956ec8
2 changed files with 2 additions and 1 deletions

View File

@ -241,6 +241,7 @@ class AOClient : public QObject {
{"BYPASS_LOCKS", 1ULL << 14},
{"IGNORE_BGLIST", 1ULL << 15},
{"SEND_NOTICE", 1ULL << 16},
{"JUKEBOX", 1ULL << 17},
{"SUPER", ~0ULL }
};

View File

@ -117,7 +117,7 @@ void AOClient::cmdToggleJukebox(int argc, QStringList argv)
Q_UNUSED(argc);
Q_UNUSED(argv);
if (checkAuth(ACLFlags.value("CM")) | m_authenticated) {
if (checkAuth(ACLFlags.value("CM")) | checkAuth(ACLFlags.value("Jukebox"))) {
AreaData* l_area = server->m_areas.value(m_current_area);
l_area->toggleJukebox();
QString l_state = l_area->isjukeboxEnabled() ? "enabled." : "disabled.";