diff options
Diffstat (limited to 'src/commands/cmd_quit.cpp')
-rw-r--r-- | src/commands/cmd_quit.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/commands/cmd_quit.cpp b/src/commands/cmd_quit.cpp index 9c0392162..e29382e84 100644 --- a/src/commands/cmd_quit.cpp +++ b/src/commands/cmd_quit.cpp @@ -38,7 +38,16 @@ CmdResult CommandQuit::Handle (const std::vector<std::string>& parameters, User else quitmsg = parameters.size() ? parameters[0] : "Client exited"; - ServerInstance->Users->QuitUser(user, quitmsg); + std::string* operquit; + if (user->GetExt("operquit", operquit)) + { + ServerInstance->Users->QuitUser(user, quitmsg, operquit->c_str()); + delete operquit; + } + else + { + ServerInstance->Users->QuitUser(user, quitmsg); + } return CMD_SUCCESS; } |