From 12a78214831cabc61df68ed562aa22b0280151de Mon Sep 17 00:00:00 2001 From: Nate Sesti Date: Fri, 3 Nov 2023 12:03:28 -0700 Subject: [PATCH] =?UTF-8?q?=F0=9F=9A=91=20hotfix=20for=20react=20error?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- gui/src/components/ComboBox.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gui/src/components/ComboBox.tsx b/gui/src/components/ComboBox.tsx index 84ccce46f..ead552366 100644 --- a/gui/src/components/ComboBox.tsx +++ b/gui/src/components/ComboBox.tsx @@ -1519,7 +1519,7 @@ const ComboBox = React.forwardRef((props: ComboBoxProps, ref) => { { const inputValue = downshiftProps.inputValue; - if (inputValue.startsWith("/codebase")) { + if (inputValue?.startsWith("/codebase")) { downshiftProps.setInputValue( inputValue.replace("/codebase ", "") ); @@ -1530,7 +1530,7 @@ const ComboBox = React.forwardRef((props: ComboBoxProps, ref) => { }} className={"hover:underline cursor-pointer float-right"} > - {downshiftProps.inputValue.startsWith("/codebase") + {downshiftProps.inputValue?.startsWith("/codebase") ? "Using codebase" : "⌘ ⏎ Use codebase"}