This commit is contained in:
Hiten 2022-07-02 23:55:45 +00:00 committed by GitHub
commit ddf9043f5b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 3 deletions

View File

@ -569,9 +569,10 @@ export class CanvasRenderer extends Renderer {
}
resizeImage(image: HTMLImageElement, width: number, height: number): HTMLCanvasElement | HTMLImageElement {
if (image.width === width && image.height === height) {
return image;
}
// if (image.width === width && image.height === height) {
// return image;
// }
const ownerDocument = this.canvas.ownerDocument ?? document;
const canvas = ownerDocument.createElement('canvas');