mirror of
https://github.com/KingDuckZ/kamokan.git
synced 2025-08-03 12:50:02 +00:00
Allow registering makers specific to POST or GET requests.
This commit is contained in:
parent
014f18ec57
commit
27881ed0f0
7 changed files with 66 additions and 13 deletions
|
@ -160,7 +160,10 @@ int main (int parArgc, char* parArgv[], char* parEnvp[]) {
|
|||
resp_factory.register_maker("error.cgi", &make_response<ErrorResponse>);
|
||||
resp_factory.register_jolly_maker(&make_response<PastieResponse>);
|
||||
|
||||
std::unique_ptr<Response> response = resp_factory.make_response(cgi_env->path_info());
|
||||
std::unique_ptr<Response> response = resp_factory.make_response(
|
||||
cgi_env->path_info(),
|
||||
cgi_env->request_method()
|
||||
);
|
||||
response->send();
|
||||
}
|
||||
catch (const std::exception& e) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue