mirror of
https://github.com/invoke-ai/InvokeAI.git
synced 2026-04-23 03:00:31 -04:00
fix(ui): reject on dataURLToImageData
This commit is contained in:
@@ -287,6 +287,11 @@ export const dataURLToImageData = (dataURL: string, width: number, height: numbe
|
||||
resolve(ctx.getImageData(0, 0, width, height));
|
||||
};
|
||||
|
||||
image.onerror = function (e) {
|
||||
canvas.remove();
|
||||
reject(e);
|
||||
};
|
||||
|
||||
image.src = dataURL;
|
||||
});
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user