@dereekb/zoho 13.4.1 → 13.4.2
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/index.cjs.js +7 -24
- package/index.esm.js +7 -24
- package/nestjs/index.cjs.js +0 -4
- package/nestjs/index.esm.js +0 -4
- package/nestjs/package.json +4 -4
- package/package.json +3 -3
package/index.cjs.js
CHANGED
|
@@ -88,15 +88,13 @@ function _object_spread_props$c(target, source) {
|
|
|
88
88
|
* const secondPage = await firstPage.fetchNext();
|
|
89
89
|
* }
|
|
90
90
|
* ```
|
|
91
|
-
*/
|
|
92
|
-
function zohoFetchPageFactory(fetch$1, defaults) {
|
|
91
|
+
*/ function zohoFetchPageFactory(fetch$1, defaults) {
|
|
93
92
|
return fetch.fetchPageFactory(_object_spread_props$c(_object_spread$d({}, defaults), {
|
|
94
93
|
fetch: fetch$1,
|
|
95
94
|
readFetchPageResultInfo: function readFetchPageResultInfo(result) {
|
|
96
95
|
var _ref;
|
|
97
96
|
var _result_info;
|
|
98
97
|
return {
|
|
99
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- info may be missing in malformed responses
|
|
100
98
|
hasNext: (_ref = (_result_info = result.info) === null || _result_info === void 0 ? void 0 : _result_info.more_records) !== null && _ref !== void 0 ? _ref : false // if no info is returned, assume something wrong and there are no more records
|
|
101
99
|
};
|
|
102
100
|
},
|
|
@@ -192,7 +190,6 @@ function _type_of$6(obj) {
|
|
|
192
190
|
*/ function zohoSearchRecordsCriteriaString(input) {
|
|
193
191
|
var result;
|
|
194
192
|
if (input != null) {
|
|
195
|
-
// eslint-disable-next-line @typescript-eslint/switch-exhaustiveness-check -- only string and object are valid for criteria input
|
|
196
193
|
switch(typeof input === "undefined" ? "undefined" : _type_of$6(input)){
|
|
197
194
|
case 'string':
|
|
198
195
|
result = input;
|
|
@@ -551,7 +548,6 @@ function _ts_generator$9(thisArg, body) {
|
|
|
551
548
|
* @param value
|
|
552
549
|
* @returns
|
|
553
550
|
*/ function isZohoServerErrorResponseDataArrayRef(value) {
|
|
554
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- value is unknown at runtime, optional chain needed for safety
|
|
555
551
|
return Array.isArray(value === null || value === void 0 ? void 0 : value.data);
|
|
556
552
|
}
|
|
557
553
|
/**
|
|
@@ -741,9 +737,7 @@ function _ts_generator$9(thisArg, body) {
|
|
|
741
737
|
* @returns Interceptor function that detects and throws hidden errors in 200 responses
|
|
742
738
|
*/ function interceptZohoErrorResponseFactory(parseZohoServerErrorResponseData) {
|
|
743
739
|
return function(json, response) {
|
|
744
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- json is typed as unknown union, optional chain needed for runtime safety
|
|
745
740
|
var error = json === null || json === void 0 ? void 0 : json.error;
|
|
746
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- error may be undefined at runtime despite cast
|
|
747
741
|
if (error != null) {
|
|
748
742
|
var responseError = new fetch.FetchResponseError(response);
|
|
749
743
|
var parsedError = parseZohoServerErrorResponseData(json, responseError);
|
|
@@ -928,7 +922,6 @@ var ZohoTooManyRequestsError = /*#__PURE__*/ function(ZohoServerFetchResponseErr
|
|
|
928
922
|
*/ function tryFindZohoServerErrorData(errorResponseData, responseError) {
|
|
929
923
|
var _ref, _errorResponseData_error;
|
|
930
924
|
var _errorResponseData_data;
|
|
931
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- errorResponseData shape is unknown at runtime, fallthrough chain needed
|
|
932
925
|
return (_ref = (_errorResponseData_error = errorResponseData.error) !== null && _errorResponseData_error !== void 0 ? _errorResponseData_error : (_errorResponseData_data = errorResponseData.data) === null || _errorResponseData_data === void 0 ? void 0 : _errorResponseData_data[0]) !== null && _ref !== void 0 ? _ref : !responseError.response.ok ? errorResponseData : undefined;
|
|
933
926
|
}
|
|
934
927
|
|
|
@@ -1263,8 +1256,7 @@ function _ts_generator$8(thisArg, body) {
|
|
|
1263
1256
|
*/ function assertZohoRecruitRecordDataArrayResultHasContent(moduleName, recordId) {
|
|
1264
1257
|
return function(x) {
|
|
1265
1258
|
var _x_data;
|
|
1266
|
-
|
|
1267
|
-
if (x == null || !((_x_data = x.data) === null || _x_data === void 0 ? void 0 : _x_data.length)) {
|
|
1259
|
+
if (!(x === null || x === void 0 ? void 0 : (_x_data = x.data) === null || _x_data === void 0 ? void 0 : _x_data.length)) {
|
|
1268
1260
|
throw new ZohoRecruitRecordNoContentError(moduleName, recordId);
|
|
1269
1261
|
} else {
|
|
1270
1262
|
return x;
|
|
@@ -1469,7 +1461,6 @@ function _is_native_reflect_construct$3() {
|
|
|
1469
1461
|
return result;
|
|
1470
1462
|
} else {
|
|
1471
1463
|
var successItems = result.successItems, errorItems = result.errorItems;
|
|
1472
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- array may be empty at runtime
|
|
1473
1464
|
if (errorItems[0] != null) {
|
|
1474
1465
|
throw zohoRecruitRecordCrudError(errorItems[0].result);
|
|
1475
1466
|
} else {
|
|
@@ -1724,7 +1715,6 @@ function _is_native_reflect_construct$3() {
|
|
|
1724
1715
|
}
|
|
1725
1716
|
return zohoRecruitUrlSearchParamsMinusModule(baseInput);
|
|
1726
1717
|
}
|
|
1727
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- fetchJson may return null for empty results
|
|
1728
1718
|
return function(input) {
|
|
1729
1719
|
return context.fetchJson("/v2/".concat(input.module, "/search?").concat(searchRecordsUrlSearchParams(input).toString()), zohoRecruitApiFetchJsonInput('GET')).then(function(x) {
|
|
1730
1720
|
return x !== null && x !== void 0 ? x : {
|
|
@@ -1797,7 +1787,7 @@ function _is_native_reflect_construct$3() {
|
|
|
1797
1787
|
return context.fetchJson("/v2/".concat(input.module, "/").concat(input.id, "/").concat(targetModule, "?").concat(zohoRecruitUrlSearchParamsMinusIdAndModule(input, input.filter).toString()), zohoRecruitApiFetchJsonInput('GET')).then(function(x) {
|
|
1798
1788
|
return x !== null && x !== void 0 ? x : returnEmptyRecordsInsteadOfNull !== false ? emptyZohoPageResult() : x;
|
|
1799
1789
|
});
|
|
1800
|
-
};
|
|
1790
|
+
};
|
|
1801
1791
|
};
|
|
1802
1792
|
}
|
|
1803
1793
|
/**
|
|
@@ -4085,8 +4075,7 @@ function _ts_generator$4(thisArg, body) {
|
|
|
4085
4075
|
*/ function assertZohoCrmRecordDataArrayResultHasContent(moduleName, recordId) {
|
|
4086
4076
|
return function(x) {
|
|
4087
4077
|
var _x_data;
|
|
4088
|
-
|
|
4089
|
-
if (x == null || !((_x_data = x.data) === null || _x_data === void 0 ? void 0 : _x_data.length)) {
|
|
4078
|
+
if (!(x === null || x === void 0 ? void 0 : (_x_data = x.data) === null || _x_data === void 0 ? void 0 : _x_data.length)) {
|
|
4090
4079
|
throw new ZohoCrmRecordNoContentError(moduleName, recordId);
|
|
4091
4080
|
} else {
|
|
4092
4081
|
return x;
|
|
@@ -4296,7 +4285,6 @@ function _is_native_reflect_construct() {
|
|
|
4296
4285
|
return result;
|
|
4297
4286
|
} else {
|
|
4298
4287
|
var successItems = result.successItems, errorItems = result.errorItems;
|
|
4299
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- array may be empty at runtime
|
|
4300
4288
|
if (errorItems[0] != null) {
|
|
4301
4289
|
throw zohoCrmRecordCrudError(errorItems[0].result);
|
|
4302
4290
|
} else {
|
|
@@ -4551,7 +4539,6 @@ function _is_native_reflect_construct() {
|
|
|
4551
4539
|
}
|
|
4552
4540
|
return zohoCrmUrlSearchParamsMinusModule(baseInput);
|
|
4553
4541
|
}
|
|
4554
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- fetchJson may return null for empty results
|
|
4555
4542
|
return function(input) {
|
|
4556
4543
|
return context.fetchJson("/v8/".concat(input.module, "/search?").concat(searchRecordsUrlSearchParams(input).toString()), zohoCrmApiFetchJsonInput('GET')).then(function(x) {
|
|
4557
4544
|
return x !== null && x !== void 0 ? x : {
|
|
@@ -4624,7 +4611,7 @@ function _is_native_reflect_construct() {
|
|
|
4624
4611
|
return context.fetchJson("/v8/".concat(input.module, "/").concat(input.id, "/").concat(targetModule, "?").concat(zohoCrmUrlSearchParamsMinusIdAndModule(input, input.filter).toString()), zohoCrmApiFetchJsonInput('GET')).then(function(x) {
|
|
4625
4612
|
return x !== null && x !== void 0 ? x : returnEmptyRecordsInsteadOfNull !== false ? emptyZohoPageResult() : x;
|
|
4626
4613
|
});
|
|
4627
|
-
};
|
|
4614
|
+
};
|
|
4628
4615
|
};
|
|
4629
4616
|
}
|
|
4630
4617
|
/**
|
|
@@ -4656,7 +4643,6 @@ function _is_native_reflect_construct() {
|
|
|
4656
4643
|
return function(input) {
|
|
4657
4644
|
return getEmailsFactory(input).then(function(x) {
|
|
4658
4645
|
var _x_data;
|
|
4659
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- Zoho API may return Emails instead of data
|
|
4660
4646
|
var data = (_x_data = x.data) !== null && _x_data !== void 0 ? _x_data : x.Emails;
|
|
4661
4647
|
return _object_spread_props$6(_object_spread$7({}, x), {
|
|
4662
4648
|
data: data
|
|
@@ -4988,8 +4974,7 @@ function _is_native_reflect_construct() {
|
|
|
4988
4974
|
*
|
|
4989
4975
|
* @param e - The error to catch and potentially convert
|
|
4990
4976
|
* @returns The error data array wrapped as a change object response
|
|
4991
|
-
*/
|
|
4992
|
-
function zohoCrmCatchZohoCrmChangeObjectLikeResponseError(e) {
|
|
4977
|
+
*/ function zohoCrmCatchZohoCrmChangeObjectLikeResponseError(e) {
|
|
4993
4978
|
var result;
|
|
4994
4979
|
if (_instanceof$3(e, ZohoServerFetchResponseDataArrayError)) {
|
|
4995
4980
|
result = {
|
|
@@ -5776,15 +5761,13 @@ function _object_spread_props$2(target, source) {
|
|
|
5776
5761
|
* const secondPage = await firstPage.fetchNext();
|
|
5777
5762
|
* }
|
|
5778
5763
|
* ```
|
|
5779
|
-
*/
|
|
5780
|
-
function zohoSignFetchPageFactory(fetch$1, defaults) {
|
|
5764
|
+
*/ function zohoSignFetchPageFactory(fetch$1, defaults) {
|
|
5781
5765
|
return fetch.fetchPageFactory(_object_spread_props$2(_object_spread$3({}, defaults), {
|
|
5782
5766
|
fetch: fetch$1,
|
|
5783
5767
|
readFetchPageResultInfo: function readFetchPageResultInfo(result) {
|
|
5784
5768
|
var _ref;
|
|
5785
5769
|
var _result_page_context;
|
|
5786
5770
|
return {
|
|
5787
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- page_context may be missing in malformed responses
|
|
5788
5771
|
hasNext: (_ref = (_result_page_context = result.page_context) === null || _result_page_context === void 0 ? void 0 : _result_page_context.has_more_rows) !== null && _ref !== void 0 ? _ref : false
|
|
5789
5772
|
};
|
|
5790
5773
|
},
|
package/index.esm.js
CHANGED
|
@@ -86,15 +86,13 @@ function _object_spread_props$c(target, source) {
|
|
|
86
86
|
* const secondPage = await firstPage.fetchNext();
|
|
87
87
|
* }
|
|
88
88
|
* ```
|
|
89
|
-
*/
|
|
90
|
-
function zohoFetchPageFactory(fetch, defaults) {
|
|
89
|
+
*/ function zohoFetchPageFactory(fetch, defaults) {
|
|
91
90
|
return fetchPageFactory(_object_spread_props$c(_object_spread$d({}, defaults), {
|
|
92
91
|
fetch: fetch,
|
|
93
92
|
readFetchPageResultInfo: function readFetchPageResultInfo(result) {
|
|
94
93
|
var _ref;
|
|
95
94
|
var _result_info;
|
|
96
95
|
return {
|
|
97
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- info may be missing in malformed responses
|
|
98
96
|
hasNext: (_ref = (_result_info = result.info) === null || _result_info === void 0 ? void 0 : _result_info.more_records) !== null && _ref !== void 0 ? _ref : false // if no info is returned, assume something wrong and there are no more records
|
|
99
97
|
};
|
|
100
98
|
},
|
|
@@ -190,7 +188,6 @@ function _type_of$6(obj) {
|
|
|
190
188
|
*/ function zohoSearchRecordsCriteriaString(input) {
|
|
191
189
|
var result;
|
|
192
190
|
if (input != null) {
|
|
193
|
-
// eslint-disable-next-line @typescript-eslint/switch-exhaustiveness-check -- only string and object are valid for criteria input
|
|
194
191
|
switch(typeof input === "undefined" ? "undefined" : _type_of$6(input)){
|
|
195
192
|
case 'string':
|
|
196
193
|
result = input;
|
|
@@ -549,7 +546,6 @@ function _ts_generator$9(thisArg, body) {
|
|
|
549
546
|
* @param value
|
|
550
547
|
* @returns
|
|
551
548
|
*/ function isZohoServerErrorResponseDataArrayRef(value) {
|
|
552
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- value is unknown at runtime, optional chain needed for safety
|
|
553
549
|
return Array.isArray(value === null || value === void 0 ? void 0 : value.data);
|
|
554
550
|
}
|
|
555
551
|
/**
|
|
@@ -739,9 +735,7 @@ function _ts_generator$9(thisArg, body) {
|
|
|
739
735
|
* @returns Interceptor function that detects and throws hidden errors in 200 responses
|
|
740
736
|
*/ function interceptZohoErrorResponseFactory(parseZohoServerErrorResponseData) {
|
|
741
737
|
return function(json, response) {
|
|
742
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- json is typed as unknown union, optional chain needed for runtime safety
|
|
743
738
|
var error = json === null || json === void 0 ? void 0 : json.error;
|
|
744
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- error may be undefined at runtime despite cast
|
|
745
739
|
if (error != null) {
|
|
746
740
|
var responseError = new FetchResponseError(response);
|
|
747
741
|
var parsedError = parseZohoServerErrorResponseData(json, responseError);
|
|
@@ -926,7 +920,6 @@ var ZohoTooManyRequestsError = /*#__PURE__*/ function(ZohoServerFetchResponseErr
|
|
|
926
920
|
*/ function tryFindZohoServerErrorData(errorResponseData, responseError) {
|
|
927
921
|
var _ref, _errorResponseData_error;
|
|
928
922
|
var _errorResponseData_data;
|
|
929
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- errorResponseData shape is unknown at runtime, fallthrough chain needed
|
|
930
923
|
return (_ref = (_errorResponseData_error = errorResponseData.error) !== null && _errorResponseData_error !== void 0 ? _errorResponseData_error : (_errorResponseData_data = errorResponseData.data) === null || _errorResponseData_data === void 0 ? void 0 : _errorResponseData_data[0]) !== null && _ref !== void 0 ? _ref : !responseError.response.ok ? errorResponseData : undefined;
|
|
931
924
|
}
|
|
932
925
|
|
|
@@ -1261,8 +1254,7 @@ function _ts_generator$8(thisArg, body) {
|
|
|
1261
1254
|
*/ function assertZohoRecruitRecordDataArrayResultHasContent(moduleName, recordId) {
|
|
1262
1255
|
return function(x) {
|
|
1263
1256
|
var _x_data;
|
|
1264
|
-
|
|
1265
|
-
if (x == null || !((_x_data = x.data) === null || _x_data === void 0 ? void 0 : _x_data.length)) {
|
|
1257
|
+
if (!(x === null || x === void 0 ? void 0 : (_x_data = x.data) === null || _x_data === void 0 ? void 0 : _x_data.length)) {
|
|
1266
1258
|
throw new ZohoRecruitRecordNoContentError(moduleName, recordId);
|
|
1267
1259
|
} else {
|
|
1268
1260
|
return x;
|
|
@@ -1467,7 +1459,6 @@ function _is_native_reflect_construct$3() {
|
|
|
1467
1459
|
return result;
|
|
1468
1460
|
} else {
|
|
1469
1461
|
var successItems = result.successItems, errorItems = result.errorItems;
|
|
1470
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- array may be empty at runtime
|
|
1471
1462
|
if (errorItems[0] != null) {
|
|
1472
1463
|
throw zohoRecruitRecordCrudError(errorItems[0].result);
|
|
1473
1464
|
} else {
|
|
@@ -1722,7 +1713,6 @@ function _is_native_reflect_construct$3() {
|
|
|
1722
1713
|
}
|
|
1723
1714
|
return zohoRecruitUrlSearchParamsMinusModule(baseInput);
|
|
1724
1715
|
}
|
|
1725
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- fetchJson may return null for empty results
|
|
1726
1716
|
return function(input) {
|
|
1727
1717
|
return context.fetchJson("/v2/".concat(input.module, "/search?").concat(searchRecordsUrlSearchParams(input).toString()), zohoRecruitApiFetchJsonInput('GET')).then(function(x) {
|
|
1728
1718
|
return x !== null && x !== void 0 ? x : {
|
|
@@ -1795,7 +1785,7 @@ function _is_native_reflect_construct$3() {
|
|
|
1795
1785
|
return context.fetchJson("/v2/".concat(input.module, "/").concat(input.id, "/").concat(targetModule, "?").concat(zohoRecruitUrlSearchParamsMinusIdAndModule(input, input.filter).toString()), zohoRecruitApiFetchJsonInput('GET')).then(function(x) {
|
|
1796
1786
|
return x !== null && x !== void 0 ? x : returnEmptyRecordsInsteadOfNull !== false ? emptyZohoPageResult() : x;
|
|
1797
1787
|
});
|
|
1798
|
-
};
|
|
1788
|
+
};
|
|
1799
1789
|
};
|
|
1800
1790
|
}
|
|
1801
1791
|
/**
|
|
@@ -4083,8 +4073,7 @@ function _ts_generator$4(thisArg, body) {
|
|
|
4083
4073
|
*/ function assertZohoCrmRecordDataArrayResultHasContent(moduleName, recordId) {
|
|
4084
4074
|
return function(x) {
|
|
4085
4075
|
var _x_data;
|
|
4086
|
-
|
|
4087
|
-
if (x == null || !((_x_data = x.data) === null || _x_data === void 0 ? void 0 : _x_data.length)) {
|
|
4076
|
+
if (!(x === null || x === void 0 ? void 0 : (_x_data = x.data) === null || _x_data === void 0 ? void 0 : _x_data.length)) {
|
|
4088
4077
|
throw new ZohoCrmRecordNoContentError(moduleName, recordId);
|
|
4089
4078
|
} else {
|
|
4090
4079
|
return x;
|
|
@@ -4294,7 +4283,6 @@ function _is_native_reflect_construct() {
|
|
|
4294
4283
|
return result;
|
|
4295
4284
|
} else {
|
|
4296
4285
|
var successItems = result.successItems, errorItems = result.errorItems;
|
|
4297
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- array may be empty at runtime
|
|
4298
4286
|
if (errorItems[0] != null) {
|
|
4299
4287
|
throw zohoCrmRecordCrudError(errorItems[0].result);
|
|
4300
4288
|
} else {
|
|
@@ -4549,7 +4537,6 @@ function _is_native_reflect_construct() {
|
|
|
4549
4537
|
}
|
|
4550
4538
|
return zohoCrmUrlSearchParamsMinusModule(baseInput);
|
|
4551
4539
|
}
|
|
4552
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- fetchJson may return null for empty results
|
|
4553
4540
|
return function(input) {
|
|
4554
4541
|
return context.fetchJson("/v8/".concat(input.module, "/search?").concat(searchRecordsUrlSearchParams(input).toString()), zohoCrmApiFetchJsonInput('GET')).then(function(x) {
|
|
4555
4542
|
return x !== null && x !== void 0 ? x : {
|
|
@@ -4622,7 +4609,7 @@ function _is_native_reflect_construct() {
|
|
|
4622
4609
|
return context.fetchJson("/v8/".concat(input.module, "/").concat(input.id, "/").concat(targetModule, "?").concat(zohoCrmUrlSearchParamsMinusIdAndModule(input, input.filter).toString()), zohoCrmApiFetchJsonInput('GET')).then(function(x) {
|
|
4623
4610
|
return x !== null && x !== void 0 ? x : returnEmptyRecordsInsteadOfNull !== false ? emptyZohoPageResult() : x;
|
|
4624
4611
|
});
|
|
4625
|
-
};
|
|
4612
|
+
};
|
|
4626
4613
|
};
|
|
4627
4614
|
}
|
|
4628
4615
|
/**
|
|
@@ -4654,7 +4641,6 @@ function _is_native_reflect_construct() {
|
|
|
4654
4641
|
return function(input) {
|
|
4655
4642
|
return getEmailsFactory(input).then(function(x) {
|
|
4656
4643
|
var _x_data;
|
|
4657
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- Zoho API may return Emails instead of data
|
|
4658
4644
|
var data = (_x_data = x.data) !== null && _x_data !== void 0 ? _x_data : x.Emails;
|
|
4659
4645
|
return _object_spread_props$6(_object_spread$7({}, x), {
|
|
4660
4646
|
data: data
|
|
@@ -4986,8 +4972,7 @@ function _is_native_reflect_construct() {
|
|
|
4986
4972
|
*
|
|
4987
4973
|
* @param e - The error to catch and potentially convert
|
|
4988
4974
|
* @returns The error data array wrapped as a change object response
|
|
4989
|
-
*/
|
|
4990
|
-
function zohoCrmCatchZohoCrmChangeObjectLikeResponseError(e) {
|
|
4975
|
+
*/ function zohoCrmCatchZohoCrmChangeObjectLikeResponseError(e) {
|
|
4991
4976
|
var result;
|
|
4992
4977
|
if (_instanceof$3(e, ZohoServerFetchResponseDataArrayError)) {
|
|
4993
4978
|
result = {
|
|
@@ -5774,15 +5759,13 @@ function _object_spread_props$2(target, source) {
|
|
|
5774
5759
|
* const secondPage = await firstPage.fetchNext();
|
|
5775
5760
|
* }
|
|
5776
5761
|
* ```
|
|
5777
|
-
*/
|
|
5778
|
-
function zohoSignFetchPageFactory(fetch, defaults) {
|
|
5762
|
+
*/ function zohoSignFetchPageFactory(fetch, defaults) {
|
|
5779
5763
|
return fetchPageFactory(_object_spread_props$2(_object_spread$3({}, defaults), {
|
|
5780
5764
|
fetch: fetch,
|
|
5781
5765
|
readFetchPageResultInfo: function readFetchPageResultInfo(result) {
|
|
5782
5766
|
var _ref;
|
|
5783
5767
|
var _result_page_context;
|
|
5784
5768
|
return {
|
|
5785
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- page_context may be missing in malformed responses
|
|
5786
5769
|
hasNext: (_ref = (_result_page_context = result.page_context) === null || _result_page_context === void 0 ? void 0 : _result_page_context.has_more_rows) !== null && _ref !== void 0 ? _ref : false
|
|
5787
5770
|
};
|
|
5788
5771
|
},
|
package/nestjs/index.cjs.js
CHANGED
|
@@ -127,7 +127,6 @@ function _define_property$c(obj, key, value) {
|
|
|
127
127
|
value: function assertValidConfig(config) {
|
|
128
128
|
var zohoAccounts = config.zohoAccounts;
|
|
129
129
|
if (!zohoAccounts) {
|
|
130
|
-
// eslint-disable-line @typescript-eslint/no-unnecessary-condition -- runtime guard for consumers passing invalid config
|
|
131
130
|
throw new Error('ZohoAccountsServiceConfig.zohoAccounts is required');
|
|
132
131
|
} else {
|
|
133
132
|
if (!zohoAccounts.serviceAccessTokenKey) {
|
|
@@ -484,7 +483,6 @@ exports.ZohoAccountsAccessTokenCacheService = __decorate([
|
|
|
484
483
|
})).then(function(x) {
|
|
485
484
|
// only find the failures if we're logging
|
|
486
485
|
if (logErrorFunction != null) {
|
|
487
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any -- PromiseSettledResult requires any for generic access
|
|
488
486
|
var failedUpdates = util.filterMaybeArrayValues(x.map(function(y) {
|
|
489
487
|
return y.value;
|
|
490
488
|
}));
|
|
@@ -737,7 +735,6 @@ var DEFAULT_FILE_ZOHO_ACCOUNTS_ACCESS_TOKEN_CACHE_SERVICE_PATH = '.tmp/zoho-acce
|
|
|
737
735
|
];
|
|
738
736
|
case 1:
|
|
739
737
|
tokens = _state.sent();
|
|
740
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- defensive guard in case loadTokens() changes
|
|
741
738
|
if (tokens) {
|
|
742
739
|
tokens[service] = accessToken;
|
|
743
740
|
}
|
|
@@ -2623,7 +2620,6 @@ var zohoSignEventHandlerFactory = util.handlerFactory(function(x) {
|
|
|
2623
2620
|
});
|
|
2624
2621
|
var zohoSignEventHandlerConfigurerFactory = util.handlerConfigurerFactory({
|
|
2625
2622
|
configurerForAccessor: function configurerForAccessor(accessor) {
|
|
2626
|
-
// eslint-disable-next-line
|
|
2627
2623
|
var fnWithKey = util.handlerMappedSetFunctionFactory(accessor, function(x) {
|
|
2628
2624
|
return x;
|
|
2629
2625
|
});
|
package/nestjs/index.esm.js
CHANGED
|
@@ -125,7 +125,6 @@ function _define_property$c(obj, key, value) {
|
|
|
125
125
|
value: function assertValidConfig(config) {
|
|
126
126
|
var zohoAccounts = config.zohoAccounts;
|
|
127
127
|
if (!zohoAccounts) {
|
|
128
|
-
// eslint-disable-line @typescript-eslint/no-unnecessary-condition -- runtime guard for consumers passing invalid config
|
|
129
128
|
throw new Error('ZohoAccountsServiceConfig.zohoAccounts is required');
|
|
130
129
|
} else {
|
|
131
130
|
if (!zohoAccounts.serviceAccessTokenKey) {
|
|
@@ -482,7 +481,6 @@ ZohoAccountsAccessTokenCacheService = __decorate([
|
|
|
482
481
|
})).then(function(x) {
|
|
483
482
|
// only find the failures if we're logging
|
|
484
483
|
if (logErrorFunction != null) {
|
|
485
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any -- PromiseSettledResult requires any for generic access
|
|
486
484
|
var failedUpdates = filterMaybeArrayValues(x.map(function(y) {
|
|
487
485
|
return y.value;
|
|
488
486
|
}));
|
|
@@ -735,7 +733,6 @@ var DEFAULT_FILE_ZOHO_ACCOUNTS_ACCESS_TOKEN_CACHE_SERVICE_PATH = '.tmp/zoho-acce
|
|
|
735
733
|
];
|
|
736
734
|
case 1:
|
|
737
735
|
tokens = _state.sent();
|
|
738
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- defensive guard in case loadTokens() changes
|
|
739
736
|
if (tokens) {
|
|
740
737
|
tokens[service] = accessToken;
|
|
741
738
|
}
|
|
@@ -2621,7 +2618,6 @@ var zohoSignEventHandlerFactory = handlerFactory(function(x) {
|
|
|
2621
2618
|
});
|
|
2622
2619
|
var zohoSignEventHandlerConfigurerFactory = handlerConfigurerFactory({
|
|
2623
2620
|
configurerForAccessor: function configurerForAccessor(accessor) {
|
|
2624
|
-
// eslint-disable-next-line
|
|
2625
2621
|
var fnWithKey = handlerMappedSetFunctionFactory(accessor, function(x) {
|
|
2626
2622
|
return x;
|
|
2627
2623
|
});
|
package/nestjs/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dereekb/zoho/nestjs",
|
|
3
|
-
"version": "13.4.
|
|
3
|
+
"version": "13.4.2",
|
|
4
4
|
"peerDependencies": {
|
|
5
|
-
"@dereekb/nestjs": "13.4.
|
|
6
|
-
"@dereekb/util": "13.4.
|
|
7
|
-
"@dereekb/zoho": "13.4.
|
|
5
|
+
"@dereekb/nestjs": "13.4.2",
|
|
6
|
+
"@dereekb/util": "13.4.2",
|
|
7
|
+
"@dereekb/zoho": "13.4.2",
|
|
8
8
|
"@nestjs/common": "^11.1.16",
|
|
9
9
|
"@nestjs/config": "^4.0.3",
|
|
10
10
|
"express": "^5.0.0"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dereekb/zoho",
|
|
3
|
-
"version": "13.4.
|
|
3
|
+
"version": "13.4.2",
|
|
4
4
|
"exports": {
|
|
5
5
|
"./nestjs": {
|
|
6
6
|
"module": "./nestjs/index.esm.js",
|
|
@@ -17,8 +17,8 @@
|
|
|
17
17
|
}
|
|
18
18
|
},
|
|
19
19
|
"peerDependencies": {
|
|
20
|
-
"@dereekb/nestjs": "13.4.
|
|
21
|
-
"@dereekb/util": "13.4.
|
|
20
|
+
"@dereekb/nestjs": "13.4.2",
|
|
21
|
+
"@dereekb/util": "13.4.2",
|
|
22
22
|
"@nestjs/common": "^11.1.16",
|
|
23
23
|
"@nestjs/config": "^4.0.3",
|
|
24
24
|
"express": "^5.0.0",
|