diff --git a/blocks/aem-asset-selector/aem-asset-selector-util.js b/blocks/aem-asset-selector/aem-asset-selector-util.js index f0d149bcc..fe910f47b 100644 --- a/blocks/aem-asset-selector/aem-asset-selector-util.js +++ b/blocks/aem-asset-selector/aem-asset-selector-util.js @@ -254,10 +254,10 @@ async function loadImageIntoHtmlElement(url) { * @param {*} targetMimeType Target mimetype (target format) * @returns A conversion promise resolving to a blob of the target mimetype */ -async function convertImage(assetPublicUrl, targetMimeType='image/png', asset) { +async function convertImage(assetPublicUrl, targetMimeType, asset) { const imageElement = await loadImageIntoHtmlElement(assetPublicUrl); - return new Promise(resolve => { + return new Promise((resolve) => { const canvas = document.createElement('canvas'); canvas.width = asset['tiff:imageWidth']; canvas.height = asset['tiff:imageLength'];