mirror of
https://github.com/n8n-io/n8n.git
synced 2025-01-23 18:41:48 -08:00
fix(shopify Node): fix pagination when empty fields are sent
This commit is contained in:
parent
82827d0a12
commit
071ab40c9f
|
@ -88,6 +88,18 @@ export async function shopifyApiRequestAllItems(
|
|||
): Promise<any> {
|
||||
const returnData: IDataObject[] = [];
|
||||
|
||||
/*
|
||||
When paginating some parameters
|
||||
(e.g. product:getAll -> title ) cannot
|
||||
be empty in the query string, so remove
|
||||
all the empty ones before paginating.
|
||||
*/
|
||||
for (const field in query) {
|
||||
if (query[field] === '') {
|
||||
delete query[field];
|
||||
}
|
||||
}
|
||||
|
||||
let responseData;
|
||||
|
||||
let uri: string | undefined;
|
||||
|
|
Loading…
Reference in a new issue