mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 18:12:04 +00:00
🐛 Fix bug with GetAll on Ghost-Node
This commit is contained in:
@@ -70,16 +70,17 @@ export async function ghostApiRequestAllItems(this: IHookFunctions | IExecuteFun
|
|||||||
|
|
||||||
let responseData;
|
let responseData;
|
||||||
|
|
||||||
query.limit = 20;
|
query.limit = 50;
|
||||||
|
query.page = 1;
|
||||||
|
|
||||||
let uri: string | undefined;
|
let uri: string | undefined;
|
||||||
|
|
||||||
do {
|
do {
|
||||||
responseData = await ghostApiRequest.call(this, method, endpoint, body, query, uri);
|
responseData = await ghostApiRequest.call(this, method, endpoint, body, query, uri);
|
||||||
uri = responseData.meta.pagination.next;
|
query.page = responseData.meta.pagination.next;
|
||||||
returnData.push.apply(returnData, responseData[propertyName]);
|
returnData.push.apply(returnData, responseData[propertyName]);
|
||||||
} while (
|
} while (
|
||||||
responseData.meta.pagination.next !== null
|
query.page !== null
|
||||||
);
|
);
|
||||||
return returnData;
|
return returnData;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user