fix(core): Remove linting exceptions in nodes-base, @typescript-eslint/no-unsafe-argument (no-changelog)

This commit is contained in:
Michael Kret
2023-02-28 05:39:43 +02:00
committed by GitHub
parent 3172ea376e
commit bb4db58819
560 changed files with 2227 additions and 1919 deletions

View File

@@ -38,11 +38,11 @@ export async function erpNextApiRequest(
options = Object.assign({}, options, option);
if (!Object.keys(options.body).length) {
if (!Object.keys(options.body as IDataObject).length) {
delete options.body;
}
if (!Object.keys(options.qs).length) {
if (!Object.keys(options.qs as IDataObject).length) {
delete options.qs;
}
try {
@@ -77,7 +77,7 @@ export async function erpNextApiRequestAllItems(
do {
responseData = await erpNextApiRequest.call(this, method, resource, body, query);
returnData.push.apply(returnData, responseData[propertyName]);
returnData.push.apply(returnData, responseData[propertyName] as IDataObject[]);
query.limit_start += query.limit_page_length - 1;
} while (responseData.data && responseData.data.length > 0);