bx-rest 0.0.33 → 0.0.35
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/fesm2020/bx-rest.mjs
CHANGED
|
@@ -1213,9 +1213,14 @@ class HttpBXServices extends HttpServices {
|
|
|
1213
1213
|
return this.httpPost(this.getNameMethod(name), params, textError, settings).pipe(map(v => {
|
|
1214
1214
|
console.log('result', v);
|
|
1215
1215
|
if (v && v.result && REST_SETTINGS.support.map && mapHttp) {
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1216
|
+
console.log('result2', mapHttp(v.result));
|
|
1217
|
+
// console.log('result2', v, Array.isArray(v.result)
|
|
1218
|
+
// ? Object.assign(v, {result: v.result.map(i => mapHttp(i))}) as iHttpAnswerBX<R>
|
|
1219
|
+
// : Object.assign(v, {result: mapHttp(v.result)}) as iHttpAnswerBX<R>)
|
|
1220
|
+
// Array.isArray(v.result)
|
|
1221
|
+
// ? Object.assign(v, {result: v.result.map(i => mapHttp(i))}) as iHttpAnswerBX<R>
|
|
1222
|
+
// :
|
|
1223
|
+
return Object.assign(v, { result: mapHttp(v.result) });
|
|
1219
1224
|
}
|
|
1220
1225
|
return v;
|
|
1221
1226
|
}), map(v => (v && REST_SETTINGS.support.result) ? mapResult : v));
|