summaryrefslogtreecommitdiff
path: root/modules/extra/webcpanel/webcpanel.h
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2012-10-07 22:39:58 -0400
committerAdam <Adam@anope.org>2012-10-07 22:39:58 -0400
commitb8b63ff115f0daddf479b0da507a2f731255a06d (patch)
treed6b82bf0dfc39fdfe6a6a23ba318bb0c2906d6c1 /modules/extra/webcpanel/webcpanel.h
parent0a111c19764ed14ab5f724c78d9dd8c08a3c124f (diff)
Remove the asynchronous identifing hack and replace it with something better. Fixes m_*_authentication only being able to properly work when people identify normally using nickserv/identify
Diffstat (limited to 'modules/extra/webcpanel/webcpanel.h')
-rw-r--r--modules/extra/webcpanel/webcpanel.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/modules/extra/webcpanel/webcpanel.h b/modules/extra/webcpanel/webcpanel.h
index 9573bbb6c..e33025b52 100644
--- a/modules/extra/webcpanel/webcpanel.h
+++ b/modules/extra/webcpanel/webcpanel.h
@@ -66,7 +66,7 @@ class WebPanelPage : public HTTPPage
{
}
- virtual void OnRequest(HTTPProvider *, const Anope::string &, HTTPClient *, HTTPMessage &, HTTPReply &) = 0;
+ virtual bool OnRequest(HTTPProvider *, const Anope::string &, HTTPClient *, HTTPMessage &, HTTPReply &) = 0;
};
class WebPanelProtectedPage : public WebPanelPage
@@ -78,14 +78,14 @@ class WebPanelProtectedPage : public WebPanelPage
{
}
- void OnRequest(HTTPProvider *provider, const Anope::string &page_name, HTTPClient *client, HTTPMessage &message, HTTPReply &reply) anope_override anope_final
+ bool OnRequest(HTTPProvider *provider, const Anope::string &page_name, HTTPClient *client, HTTPMessage &message, HTTPReply &reply) anope_override anope_final
{
service_reference<Panel> panel("Panel", "webcpanel");
NickAlias *na;
if (!panel || !(na = panel->GetNickFromSession(client, message)))
{
- return; // Access denied
+ return true; // Access denied
}
TemplateFileServer::Replacements replacements;
@@ -123,10 +123,10 @@ class WebPanelProtectedPage : public WebPanelPage
}
}
- this->OnRequest(provider, page_name, client, message, reply, na, replacements);
+ return this->OnRequest(provider, page_name, client, message, reply, na, replacements);
}
- virtual void OnRequest(HTTPProvider *, const Anope::string &, HTTPClient *, HTTPMessage &, HTTPReply &, NickAlias *, TemplateFileServer::Replacements &) = 0;
+ virtual bool OnRequest(HTTPProvider *, const Anope::string &, HTTPClient *, HTTPMessage &, HTTPReply &, NickAlias *, TemplateFileServer::Replacements &) = 0;
/* What get data should be appended to links in the navbar */
virtual std::set<Anope::string> GetData() { return std::set<Anope::string>(); }