Skip to content

Question about @Valide in Todo project #21

@sunbyte

Description

@sunbyte

Hello!

I have question about spring boot validation in Todo project.

public String addNewTodo(ModelMap modelMap, @Valid Todo todo, BindingResult bindingResult) {...}

If we change the position of the method parameters and put @Valid Todo todo before ModelMap modelMap, the validation not work correct and we don't see the error message in the form, but getting an exceptions in the browser. Why?

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions