Closed patrickcousins closed 8 years ago
more example api errors
{"errors":[
{
"id":"VALIDATION_ERROR",
"title":"Email error",
"detail":"Email is invalid",
"status":422
},
{
"id":"VALIDATION_ERROR",
"title":"Password error",
"detail":"Password can't be blank",
"status":422
}
]}
Could also separate Error parsing and rename the service to ToastService
Error display crashes on:
{"errors":[{"id":"VALIDATION_ERROR","title":"Email error","detail":"Email is invalid","status":422},{"id":"VALIDATION_ERROR","title":"Password error","detail":"Password can't be blank","status":422}]}
Caused by: com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 13 path $.errors[0]