Skip to content

Commit

Permalink
fix: never write undefined (#11)
Browse files Browse the repository at this point in the history
Co-authored-by: naiba <[email protected]>
  • Loading branch information
uubulb and naiba authored Nov 30, 2024
1 parent eb044d4 commit d1ac4fa
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/install-commands.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ export const InstallCommandsMenu = forwardRef<HTMLButtonElement, ButtonProps>((p
if (!copy) {
try {
setCopy(true);
if (settings)
await navigator.clipboard.writeText(generateCommand(type, settings));
if (config)
await navigator.clipboard.writeText(generateCommand(type, settings) || '');
} catch (e) {
console.error(e);
toast(t("Error"), {
Expand Down

0 comments on commit d1ac4fa

Please sign in to comment.