mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-01-25 15:55:18 +00:00
Remove hard coded max_items in history API
This commit is contained in:
parent
39e75862b2
commit
6aa1bcd601
@ -254,9 +254,9 @@ class ComfyApi extends EventTarget {
|
||||
* Gets the prompt execution history
|
||||
* @returns Prompt history including node outputs
|
||||
*/
|
||||
async getHistory() {
|
||||
async getHistory(max_items=200) {
|
||||
try {
|
||||
const res = await this.fetchApi("/history?max_items=200");
|
||||
const res = await this.fetchApi(`/history?max_items=${max_items}`);
|
||||
return { History: Object.values(await res.json()) };
|
||||
} catch (error) {
|
||||
console.error(error);
|
||||
|
Loading…
Reference in New Issue
Block a user