From dbe5a1fc6f9e18765863f332a3e79d7c918d3e65 Mon Sep 17 00:00:00 2001 From: Attila Molnar Date: Thu, 25 Feb 2016 16:40:50 +0100 Subject: Add User::WriteRemoteNumeric() and switch code using SendText() to send numerics to it --- src/modules/m_showfile.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/modules/m_showfile.cpp') diff --git a/src/modules/m_showfile.cpp b/src/modules/m_showfile.cpp index cb51c4387..9973bf2b6 100644 --- a/src/modules/m_showfile.cpp +++ b/src/modules/m_showfile.cpp @@ -48,12 +48,12 @@ class CommandShowFile : public Command if (method == SF_NUMERIC) { if (!introtext.empty()) - user->SendText(":%s %03d %s :%s %s", sn.c_str(), intronumeric, user->nick.c_str(), sn.c_str(), introtext.c_str()); + user->WriteRemoteNumeric(intronumeric, introtext); for (file_cache::const_iterator i = contents.begin(); i != contents.end(); ++i) - user->SendText(":%s %03d %s :- %s", sn.c_str(), textnumeric, user->nick.c_str(), i->c_str()); + user->WriteRemoteNumeric(textnumeric, InspIRCd::Format("- %s", i->c_str())); - user->SendText(":%s %03d %s :%s", sn.c_str(), endnumeric, user->nick.c_str(), endtext.c_str()); + user->WriteRemoteNumeric(endnumeric, endtext.c_str()); } else { -- cgit v1.3.1-10-gc9f91