From 71c4c8c35bdf85fb27ea1c705afa76520054045a Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 19 Dec 2022 18:27:23 +0000 Subject: [PATCH] chore: code formatting --- source/plugins/community/screenshot/index.mjs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/plugins/community/screenshot/index.mjs b/source/plugins/community/screenshot/index.mjs index cd6a3b1e..2c4d5521 100644 --- a/source/plugins/community/screenshot/index.mjs +++ b/source/plugins/community/screenshot/index.mjs @@ -25,10 +25,10 @@ export default async function({login, q, imports, data, account}, {enabled = fal //Screenshot let content = null let image = null - const metadata = {height:null, width:null} + const metadata = {height: null, width: null} await page.waitForSelector(selector) switch (mode) { - case "image":{ + case "image": { const clip = await page.evaluate(selector => { const {x, y, width, height} = document.querySelector(selector).getBoundingClientRect() return {x, y, width, height} @@ -40,7 +40,7 @@ export default async function({login, q, imports, data, account}, {enabled = fal Object.assign(metadata, await screenshot.metadata()) break } - case "text":{ + case "text": { content = await page.evaluate(selector => document.querySelector(selector)?.innerText ?? "", selector) break }