From d549e0c4c5623eb64f7047ad5b0a146bfddbc11a Mon Sep 17 00:00:00 2001 From: WolverinDEV Date: Tue, 23 Jul 2019 10:17:35 +0200 Subject: [PATCH] Fixed missing permission --- server/src/client/ConnectedClientCommandHandler.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/server/src/client/ConnectedClientCommandHandler.cpp b/server/src/client/ConnectedClientCommandHandler.cpp index ff237c8..2bf778b 100644 --- a/server/src/client/ConnectedClientCommandHandler.cpp +++ b/server/src/client/ConnectedClientCommandHandler.cpp @@ -1668,7 +1668,7 @@ inline ssize_t count_characters(const std::string& in) { * 3. Apply changed, test for advanced requirements like channel name etc * 4. notify everyone */ -CommandResult ConnectedClient::handleCommandChannelEdit(Command &cmd) { +CommandResult ConnectedClient:handleCommandChannelEdit(Command &cmd) { CMD_RESET_IDLE; CMD_CHK_AND_INC_FLOOD_POINTS(25); @@ -1692,6 +1692,8 @@ CommandResult ConnectedClient::handleCommandChannelEdit(Command &cmd) { bool target_channel_type_changed = false; ChannelType::ChannelType target_channel_type = channel->channelType(); CHANNEL_PERM_TEST_INIT; + CHANNEL_PERMISSION_TEST(permission::i_channel_modify_power, permission::i_channel_needed_modify_power, channel, true); + for (const auto &key : cmd[0].keys()) { if(key == "cid") continue;