Fixed ajax submission after validation