MCPcopy
hub / github.com/jquery/esprima / transformData

Function transformData

test/3rdparty/angular-1.2.5.js:6852–6861  ·  view source on GitHub ↗

* Chain all given functions * * This function is used for both request and response transforming * * @param {*} data Data to transform. * @param {function(string=)} headers Http headers getter fn. * @param {(function|Array. )} fns Function or an array of functions. * @returns {*} Tra

(data, headers, fns)

Source from the content-addressed store, hash-verified

6850 * @returns {*} Transformed data.
6851 */
6852function transformData(data, headers, fns) {
6853 if (isFunction(fns))
6854 return fns(data, headers);
6855
6856 forEach(fns, function(fn) {
6857 data = fn(data, headers);
6858 });
6859
6860 return data;
6861}
6862
6863
6864function isSuccess(status) {

Callers 2

serverRequestFunction · 0.85
transformResponseFunction · 0.85

Calls 2

isFunctionFunction · 0.85
forEachFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…