chore: code formatting

This commit is contained in:
github-actions[bot]
2022-06-29 04:44:10 +00:00
parent 2ff392e5d2
commit e8156294db

View File

@@ -332,7 +332,7 @@ export async function imgb64(image, {width, height, fallback = true} = {}) {
//Load image //Load image
try { try {
//Fix: redirections are not properly supported by jimp (https://github.com/oliver-moran/jimp/issues/909), seems to occur only when in jest environment //Fix: redirections are not properly supported by jimp (https://github.com/oliver-moran/jimp/issues/909), seems to occur only when in jest environment
if ((typeof image === "string") && ((process.env.JEST_WORKER_ID)||(process.env.METRICS_MOCKED))) { if ((typeof image === "string") && ((process.env.JEST_WORKER_ID) || (process.env.METRICS_MOCKED))) {
image = (await axios.get(image)).then(response => response.request.responseURL).catch(() => null) image = (await axios.get(image)).then(response => response.request.responseURL).catch(() => null)
console.debug(`metrics/svg/imgb64 > redirected image link to ${image}`) console.debug(`metrics/svg/imgb64 > redirected image link to ${image}`)
} }