Ajax get an error when form is failing
TODO: get flash messages in AJAX