From d08d7301637787d9d553bbf7de5e28b8f081d9af Mon Sep 17 00:00:00 2001 From: MarcusNyne <69087098+MarcusNyne@users.noreply.github.com> Date: Sat, 24 Aug 2024 17:56:41 -0400 Subject: [PATCH] javascript linting --- script.js | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/script.js b/script.js index ca6c80ee2..1a0906067 100644 --- a/script.js +++ b/script.js @@ -241,29 +241,30 @@ function uiCopyPngInfo(el, mode) { if (mode == "Positive") { text = uiCopyRawText("pnginfo-positive"); - } - else if (mode == "Negative") { + } else if (mode == "Negative") { text = uiCopyRawText("pnginfo-negative"); - } - else if (mode == "Settings") { + } else if (mode == "Settings") { text = uiCopyRawText("pnginfo-settings"); - } - else if (mode == "All") { + } else if (mode == "All") { text = ""; var t2 = uiCopyRawText("pnginfo-positive"); - if (t2 != null) + if (t2 != null) { text += t2; + } t2 = uiCopyRawText("pnginfo-negative"); - if (t2 != null) - text += "\nNegative prompt:" + t2; + if (t2 != null) { + text += "\nNegative prompt: " + t2; + } t2 = uiCopyRawText("pnginfo-settings"); - if (t2 != null) + if (t2 != null) { text += "\n" + t2; - if (text == "") + } + if (text == "") { text = null; + } } - if (text!=null) { + if (text != null) { navigator.clipboard.writeText(text); el.classList.remove('animate');