Skip to content

Commit dfea072

Browse files
committed
fix(better-copy-buttons): null sources element handling
1 parent 98387b7 commit dfea072

File tree

1 file changed

+1
-3
lines changed
  • src/plugins/thread-better-message-copy-buttons

1 file changed

+1
-3
lines changed

src/plugins/thread-better-message-copy-buttons/index.tsx

+1-3
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,7 @@ export default function BetterMessageCopyButton({
1111
deepEqual,
1212
);
1313

14-
if (!$sources) return null;
15-
16-
const hasSources = $sources.length > 0;
14+
const hasSources = $sources != null && $sources.length > 0;
1715

1816
return (
1917
<CopyButton messageBlockIndex={messageBlockIndex} hasSources={hasSources} />

0 commit comments

Comments
 (0)