Skip to content

Commit aa5a6ee

Browse files
committed
Add upgrading note regarding the general error structure
1 parent fd0102e commit aa5a6ee

File tree

1 file changed

+24
-2
lines changed

1 file changed

+24
-2
lines changed

UPGRADING.md

Lines changed: 24 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,30 @@ list important BC breaks.
66

77
### upgrading from 0.13.1
88

9-
* POST routes now pluralize the resource name, ie. /users vs. /user
10-
* The response for non-valid Forms has changed. See https://github.com/FriendsOfSymfony/FOSRestBundle/blob/master/Resources/doc/2-the-view-layer.md#forms-and-views
9+
* POST routes now pluralize the resource name, ie. /users vs. /user
10+
11+
* The response for non-valid Forms has changed. See https://github.com/FriendsOfSymfony/FOSRestBundle/blob/master/Resources/doc/2-the-view-layer.md#forms-and-views
12+
13+
* The default error message structure has changed.
14+
15+
_Old structure_
16+
17+
{
18+
"status": "error",
19+
"status_code": 400,
20+
"status_text": "Bad Request",
21+
"current_content": "",
22+
"message": "New comment is not valid."
23+
}
24+
25+
_New structure_
26+
27+
{
28+
"code": 400,
29+
"message": "New comment is not valid.";
30+
}
31+
32+
_Alternatively you can inject your own implementation. See https://github.com/FriendsOfSymfony/FOSRestBundle/blob/master/Resources/doc/2-the-view-layer.md#forms-and-views_
1133

1234
### upgrading from 0.12.0
1335

0 commit comments

Comments
 (0)