From 8b694bc392c36551e428b84454efb81cdbc8bcd3 Mon Sep 17 00:00:00 2001 From: Adam Date: Mon, 6 Feb 2017 14:23:18 -0500 Subject: Track override in CommandSource and use it in the logger --- modules/hostserv/add.cpp | 2 +- modules/hostserv/del.cpp | 4 ++-- modules/hostserv/off.cpp | 2 +- modules/hostserv/on.cpp | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) (limited to 'modules/hostserv') diff --git a/modules/hostserv/add.cpp b/modules/hostserv/add.cpp index 3448dbc41..37de7d2bb 100644 --- a/modules/hostserv/add.cpp +++ b/modules/hostserv/add.cpp @@ -101,7 +101,7 @@ class CommandHSAdd : public Command } Anope::string mask = (!user.empty() ? user + "@" : "") + host; - logger.Command(LogType::ADMIN, source, _("{source} used {command} to add the vhost {0} to {1}"), mask, na->GetAccount()->GetDisplay()); + logger.Admin(source, _("{source} used {command} to add the vhost {0} to {1}"), mask, na->GetAccount()->GetDisplay()); HostServ::VHost *vhost = Serialize::New(); if (vhost == nullptr) diff --git a/modules/hostserv/del.cpp b/modules/hostserv/del.cpp index a72c61c9a..632af1716 100644 --- a/modules/hostserv/del.cpp +++ b/modules/hostserv/del.cpp @@ -54,7 +54,7 @@ class CommandHSDel : public Command return; } - logger.Command(LogType::ADMIN, source, _("{source} used {command} on {0} to remove vhost {1}"), na->GetAccount()->GetDisplay(), vhost->Mask()); + logger.Admin(source, _("{source} used {command} on {0} to remove vhost {1}"), na->GetAccount()->GetDisplay(), vhost->Mask()); source.Reply(_("Vhost \002{0}\002 for \002{1}\002 has been removed."), vhost->Mask(), na->GetAccount()->GetDisplay()); vhost->Delete(); return; @@ -67,7 +67,7 @@ class CommandHSDel : public Command return; } - logger.Command(LogType::ADMIN, source, _("{source} used {command} on {0}"), na->GetAccount()->GetDisplay()); + logger.Admin(source, _("{source} used {command} on {0}"), na->GetAccount()->GetDisplay()); #warning "send account" EventManager::Get()->Dispatch(&Event::DeleteVhost::OnDeleteVhost, na); diff --git a/modules/hostserv/off.cpp b/modules/hostserv/off.cpp index 861fd00b8..7e1411a4d 100644 --- a/modules/hostserv/off.cpp +++ b/modules/hostserv/off.cpp @@ -43,7 +43,7 @@ class CommandHSOff : public Command // XXX vident? u->vhost.clear(); IRCD->Send(u); - logger.Command(LogType::ADMIN, source, _("{source} used {command} to disable their vhost")); + logger.Admin(source, _("{source} used {command} to disable their vhost")); source.Reply(_("Your vhost was removed and the normal cloaking restored.")); } diff --git a/modules/hostserv/on.cpp b/modules/hostserv/on.cpp index 556b2f567..d0a59b2ba 100644 --- a/modules/hostserv/on.cpp +++ b/modules/hostserv/on.cpp @@ -59,7 +59,7 @@ class CommandHSOn : public Command source.Reply(_("Your vhost of \002{0}\002 is now activated."), vhost->Mask()); - logger.Command(LogType::ADMIN, source, _("{source} used {command} to enable their vhost of {0}"), vhost->Mask()); + logger.Admin(source, _("{source} used {command} to enable their vhost of {0}"), vhost->Mask()); IRCD->Send(u, vhost->GetIdent(), vhost->GetHost()); u->vhost = vhost->GetHost(); if (IRCD->CanSetVIdent && !vhost->GetIdent().empty()) -- cgit