diff options
author | Sadie Powell <sadie@witchery.services> | 2024-02-21 15:39:40 +0000 |
---|---|---|
committer | Sadie Powell <sadie@witchery.services> | 2024-02-22 00:14:08 +0000 |
commit | 8475697e3b9154a018f9bba59e93366a8f835100 (patch) | |
tree | f1be3135141dbde1a8d9b13b538c68c199737e71 | |
parent | 85687781d11b7a8fb14cad061e6c635c0bc71ea0 (diff) |
Inline, constify, and document GetProtocolName.
-rw-r--r-- | include/protocol.h | 4 | ||||
-rw-r--r-- | src/protocol.cpp | 5 |
2 files changed, 3 insertions, 6 deletions
diff --git a/include/protocol.h b/include/protocol.h index e33640e77..70e45837e 100644 --- a/include/protocol.h +++ b/include/protocol.h @@ -25,6 +25,9 @@ class CoreExport IRCDProto protected: IRCDProto(Module *creator, const Anope::string &proto_name); public: + /** Retrieves the protocol name. */ + const Anope::string &GetProtocolName() const { return proto_name; } + virtual ~IRCDProto(); virtual void SendSVSKillInternal(const MessageSource &, User *, const Anope::string &); @@ -39,7 +42,6 @@ public: virtual void SendCTCPInternal(const MessageSource &, const Anope::string &dest, const Anope::string &buf); virtual void SendNumericInternal(int numeric, const Anope::string &dest, const Anope::string &buf); - const Anope::string &GetProtocolName(); virtual bool Parse(const Anope::string &, Anope::map<Anope::string> &, Anope::string &, Anope::string &, std::vector<Anope::string> &); virtual Anope::string Format(const Anope::string &source, const Anope::string &message); diff --git a/src/protocol.cpp b/src/protocol.cpp index 87efc7894..5630c3e34 100644 --- a/src/protocol.cpp +++ b/src/protocol.cpp @@ -35,11 +35,6 @@ IRCDProto::~IRCDProto() IRCD = NULL; } -const Anope::string &IRCDProto::GetProtocolName() -{ - return this->proto_name; -} - static inline char nextID(int pos, Anope::string &buf) { char &c = buf[pos]; |