class CompetitionSetupApplicationController {

    @PostMapping(value = "/landing-page", params = "createQuestion")
    public String createQuestion(@PathVariable long competitionId) {
        ServiceResult<CompetitionSetupQuestionResource> result = questionSetupCompetitionRestService
                .addDefaultToCompetition(competitionId).toServiceResult();

        Function<CompetitionSetupQuestionResource, String> successViewFunction =
                (question) -> String.format("redirect:/competition/setup/%d/section/application/question/%d/edit", competitionId, question.getQuestionId());
        return successViewFunction.apply(result.getSuccess());
    }

}