]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_httpd_stats.cpp
Change the API of m_sslinfo to be dynamic_reference-based
[user/henk/code/inspircd.git] / src / modules / m_httpd_stats.cpp
index 2eb9f7cb75b87719b0ea22347fb380fdeb6a807a..99909d97fac76c47fc72ad3e0f8e222f47e30bbb 100644 (file)
@@ -22,7 +22,7 @@
 
 
 #include "inspircd.h"
-#include "httpd.h"
+#include "modules/httpd.h"
 #include "xline.h"
 #include "protocol.h"
 
@@ -34,7 +34,7 @@ class ModuleHttpStats : public Module
 
  public:
 
-       void init()
+       void init() CXX11_OVERRIDE
        {
                Implementation eventlist[] = { I_OnEvent };
                ServerInstance->Modules->Attach(eventlist, this, sizeof(eventlist)/sizeof(Implementation));
@@ -91,13 +91,13 @@ class ModuleHttpStats : public Module
                data << "</metadata>";
        }
 
-       void OnEvent(Event& event)
+       void OnEvent(Event& event) CXX11_OVERRIDE
        {
                std::stringstream data("");
 
                if (event.id == "httpd_url")
                {
-                       ServerInstance->Logs->Log("m_http_stats", LOG_DEBUG,"Handling httpd event");
+                       ServerInstance->Logs->Log("m_http_stats", LOG_DEBUG, "Handling httpd event");
                        HTTPRequest* http = (HTTPRequest*)&event;
 
                        if ((http->GetURI() == "/stats") || (http->GetURI() == "/stats/"))
@@ -196,7 +196,7 @@ class ModuleHttpStats : public Module
                                        if (u->IsAway())
                                                data << "<away>" << Sanitize(u->awaymsg) << "</away><awaytime>" << u->awaytime << "</awaytime>";
                                        if (u->IsOper())
-                                               data << "<opertype>" << Sanitize(u->oper->NameStr()) << "</opertype>";
+                                               data << "<opertype>" << Sanitize(u->oper->name) << "</opertype>";
                                        data << "<modes>" << u->FormatModes() << "</modes><ident>" << Sanitize(u->ident) << "</ident>";
                                        LocalUser* lu = IS_LOCAL(u);
                                        if (lu)
@@ -238,7 +238,7 @@ class ModuleHttpStats : public Module
                }
        }
 
-       virtual Version GetVersion()
+       Version GetVersion() CXX11_OVERRIDE
        {
                return Version("Provides statistics over HTTP via m_httpd.so", VF_VENDOR);
        }