summaryrefslogtreecommitdiff
path: root/modules/extra/webcpanel/pages/hostserv/request.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/extra/webcpanel/pages/hostserv/request.cpp')
-rw-r--r--modules/extra/webcpanel/pages/hostserv/request.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/modules/extra/webcpanel/pages/hostserv/request.cpp b/modules/extra/webcpanel/pages/hostserv/request.cpp
index aad933c3a..20b4f5740 100644
--- a/modules/extra/webcpanel/pages/hostserv/request.cpp
+++ b/modules/extra/webcpanel/pages/hostserv/request.cpp
@@ -16,10 +16,8 @@ bool WebCPanel::HostServ::Request::OnRequest(HTTPProvider *server, const Anope::
if (message.post_data.count("req") > 0)
{
std::vector<Anope::string> params;
- std::stringstream cmdstr;
+ params.push_back(HTTPUtils::URLDecode(message.post_data["req"]));
- cmdstr << HTTPUtils::URLDecode(message.post_data["req"]);
- params.push_back(cmdstr.str());
WebPanel::RunCommand(na->nc->display, na->nc, Config->HostServ, "hostserv/request", params, replacements);
}
@@ -30,6 +28,8 @@ bool WebCPanel::HostServ::Request::OnRequest(HTTPProvider *server, const Anope::
else
replacements["VHOST"] = na->GetVhostHost();
}
+ if (ServiceReference<Command>("Command", "hostserv/request"))
+ replacements["CAN_REQUEST"] = "YES";
TemplateFileServer page("hostserv/request.html");
page.Serve(server, page_name, client, message, reply, replacements);
return true;