Copy only string git errors in error toasts
- Restrict the copy-error action to string descriptions - Avoid passing non-string toast descriptions to the clipboard
This commit is contained in:
1 parent
5568558b50
commit
e68526fc19
1 file changed
+1
-1
@@ -405,7 +405,7 @@ function AnchoredToasts() {
|
||||
className="min-w-0 break-words font-medium"
|
||||
data-slot="toast-title"
|
||||
/>
|
||||
{toast.type === "error" && toast.description && (
|
||||
{toast.type === "error" && typeof toast.description === "string" && (
|
||||
<CopyErrorButton text={toast.description} />
|
||||
)}
|
||||
</div>
|
||||
|
||||
Reference in new issue
Block a user