diff options
author | Peter Powell <petpow@saberuk.com> | 2017-08-25 13:12:44 +0100 |
---|---|---|
committer | Peter Powell <petpow@saberuk.com> | 2017-08-25 13:12:44 +0100 |
commit | 1f2a8e4db6a4c722de4e090fcd7f710d874de1ed (patch) | |
tree | d5c73c5a2e715a3384ed03d4a5866d2d1b3ed7b3 /src/modules | |
parent | 3469711d299d342ce07660d065fd31e0b3ae2e05 (diff) |
Fix mistakenly hardcoding the halfop prefix char in timedbans.
This will almost always be % but if the server admin is using the
customprefix module and remaps it to something else messages will
not be sent out correctly.
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/m_timedbans.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/modules/m_timedbans.cpp b/src/modules/m_timedbans.cpp index b47327704..61095d6eb 100644 --- a/src/modules/m_timedbans.cpp +++ b/src/modules/m_timedbans.cpp @@ -119,7 +119,7 @@ class CommandTban : public Command // If halfop is loaded, send notice to halfops and above, otherwise send to ops and above ModeHandler* mh = ServerInstance->Modes->FindMode('h', MODETYPE_CHANNEL); - char pfxchar = (mh && mh->name == "halfop") ? '%' : '@'; + char pfxchar = (mh && mh->name == "halfop") ? mh->GetPrefix() : '@'; channel->WriteAllExcept(ServerInstance->FakeClient, true, pfxchar, tmp, "NOTICE %s :%s added a timed ban on %s lasting for %ld seconds.", channel->name.c_str(), user->nick.c_str(), mask.c_str(), duration); return CMD_SUCCESS; |