refactor(core): Introduce overload for number-type node parameter (no-changelog) (#4644)

* 📘 Set up overloads

* 📘 Add temporary assertion

* 🔥 Remove inferrable number assertions

* ✏️ Add ticket ref
This commit is contained in:
Iván Ovejero
2022-11-18 15:26:22 +01:00
committed by GitHub
parent 600b285a44
commit 0565194473
166 changed files with 783 additions and 689 deletions

View File

@@ -392,7 +392,7 @@ export class Coda implements INodeType {
qs,
);
} else {
qs.limit = this.getNodeParameter('limit', 0) as number;
qs.limit = this.getNodeParameter('limit', 0);
responseData = await codaApiRequest.call(this, 'GET', endpoint, {}, qs);
responseData = responseData.items;
}
@@ -510,7 +510,7 @@ export class Coda implements INodeType {
if (returnAll) {
responseData = await codaApiRequestAllItems.call(this, 'items', 'GET', endpoint, {});
} else {
qs.limit = this.getNodeParameter('limit', 0) as number;
qs.limit = this.getNodeParameter('limit', 0);
responseData = await codaApiRequest.call(this, 'GET', endpoint, {}, qs);
responseData = responseData.items;
}
@@ -572,7 +572,7 @@ export class Coda implements INodeType {
if (returnAll) {
responseData = await codaApiRequestAllItems.call(this, 'items', 'GET', endpoint, {});
} else {
qs.limit = this.getNodeParameter('limit', 0) as number;
qs.limit = this.getNodeParameter('limit', 0);
responseData = await codaApiRequest.call(this, 'GET', endpoint, {}, qs);
responseData = responseData.items;
}
@@ -634,7 +634,7 @@ export class Coda implements INodeType {
if (returnAll) {
responseData = await codaApiRequestAllItems.call(this, 'items', 'GET', endpoint, {});
} else {
qs.limit = this.getNodeParameter('limit', 0) as number;
qs.limit = this.getNodeParameter('limit', 0);
responseData = await codaApiRequest.call(this, 'GET', endpoint, {}, qs);
responseData = responseData.items;
}
@@ -684,7 +684,7 @@ export class Coda implements INodeType {
if (returnAll) {
responseData = await codaApiRequestAllItems.call(this, 'items', 'GET', endpoint, {});
} else {
qs.limit = this.getNodeParameter('limit', 0) as number;
qs.limit = this.getNodeParameter('limit', 0);
responseData = await codaApiRequest.call(this, 'GET', endpoint, {}, qs);
responseData = responseData.items;
}
@@ -738,7 +738,7 @@ export class Coda implements INodeType {
qs,
);
} else {
qs.limit = this.getNodeParameter('limit', 0) as number;
qs.limit = this.getNodeParameter('limit', 0);
responseData = await codaApiRequest.call(this, 'GET', endpoint, {}, qs);
responseData = responseData.items;
}
@@ -828,7 +828,7 @@ export class Coda implements INodeType {
if (returnAll) {
responseData = await codaApiRequestAllItems.call(this, 'items', 'GET', endpoint, {});
} else {
qs.limit = this.getNodeParameter('limit', 0) as number;
qs.limit = this.getNodeParameter('limit', 0);
responseData = await codaApiRequest.call(this, 'GET', endpoint, {}, qs);
responseData = responseData.items;
}