From 384c967a243f9bf4fade6e3f130e44a83a8d8140 Mon Sep 17 00:00:00 2001 From: Stefan Pejcic Date: Sat, 1 Jun 2024 15:38:52 +0200 Subject: [PATCH] Update index.tsx --- documentation/src/pages/install/index.tsx | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/documentation/src/pages/install/index.tsx b/documentation/src/pages/install/index.tsx index 558b4aa2..e7ebeb1f 100644 --- a/documentation/src/pages/install/index.tsx +++ b/documentation/src/pages/install/index.tsx @@ -59,11 +59,11 @@ const Install: React.FC = () => { let command = "bash <(curl -sSL https://get.openpanel.co/)"; for (const option in installOptions) { if (option !== "version" || (option === "version" && installOptions[option].value !== latestVersion)) { - if (installOptions[option].value) { - if (option === "screenshots" && installOptions[option].value === "local") { // Modified - command += ` --screenshots=local`; // Modified + if (installOptions[option].value !== "") { + if (option === "screenshots" && installOptions[option].value === "local") { + command += ` --screenshots=local`; } else if (option !== "screenshots") { - command += ` --${option.replace(/-/g, '_')}=${installOptions[option].value}`; + command += ` --${option}${installOptions[option].value === true ? '' : `=${installOptions[option].value}`}`; } } } @@ -71,6 +71,7 @@ const Install: React.FC = () => { return command; }; + return (