Skip to content

Commit eac5f8e

Browse files
BBlackwopetebacondarwin
authored andcommitted
docs($resource): add status param to transformResponse signature
Add `status` param to `transformResponse` signature to keep inline with 1b74097. Closes angular#15041
1 parent 460e609 commit eac5f8e

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/ngResource/resource.js

+4-3
Original file line numberDiff line numberDiff line change
@@ -159,12 +159,13 @@ function shallowClearAndCopy(src, dst) {
159159
* transform function or an array of such functions. The transform function takes the http
160160
* request body and headers and returns its transformed (typically serialized) version.
161161
* By default, transformRequest will contain one function that checks if the request data is
162-
* an object and serializes to using `angular.toJson`. To prevent this behavior, set
162+
* an object and serializes it using `angular.toJson`. To prevent this behavior, set
163163
* `transformRequest` to an empty array: `transformRequest: []`
164164
* - **`transformResponse`** –
165-
* `{function(data, headersGetter)|Array.<function(data, headersGetter)>}` –
165+
* `{function(data, headersGetter, status)|Array.<function(data, headersGetter, status)>}` –
166166
* transform function or an array of such functions. The transform function takes the http
167-
* response body and headers and returns its transformed (typically deserialized) version.
167+
* response body, headers and status and returns its transformed (typically deserialized)
168+
* version.
168169
* By default, transformResponse will contain one function that checks if the response looks
169170
* like a JSON string and deserializes it using `angular.fromJson`. To prevent this behavior,
170171
* set `transformResponse` to an empty array: `transformResponse: []`

0 commit comments

Comments
 (0)