summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/service.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/service.h b/include/service.h
index 745c28cd3..af5e2d9e3 100644
--- a/include/service.h
+++ b/include/service.h
@@ -68,6 +68,18 @@ public:
return keys;
}
+ static std::vector<Service *> GetServices(const Anope::string &t)
+ {
+ std::vector<Service *> values;
+ const auto it = Services.find(t);
+ if (it != Services.end())
+ {
+ for (const auto &[_, value] : it->second)
+ values.push_back(value);
+ }
+ return values;
+ }
+
static void AddAlias(const Anope::string &t, const Anope::string &n, const Anope::string &v)
{
std::map<Anope::string, Anope::string> &smap = Aliases[t];