Merge branch 'master' into async_executor_with_scheduler

This commit is contained in:
lganzzzo 2019-04-18 03:19:29 +03:00
commit 32523ca6c7

View File

@ -135,9 +135,7 @@ ENDPOINT_ASYNC("POST", "demo/api_async/json", PostJSONAsync) {
ENDPOINT_ASYNC_INIT(PostJSONAsync) ENDPOINT_ASYNC_INIT(PostJSONAsync)
Action act() override { Action act() override {
return request->readBodyToDtoAsync<MyDto>(this, return request->readBodyToDtoAsync<MyDto>(controller->getDefaultObjectMapper()).callbackTo(&PostJSONAsync::onBodyObtained);
&PostJSONAsync::onBodyObtained,
controller->getDefaultObjectMapper());
} }
Action onBodyObtained(const MyDto::ObjectWrapper& dto) { Action onBodyObtained(const MyDto::ObjectWrapper& dto) {