Skip to content

Commit 0d19bde

Browse files
committed
Fix TypeScript error: Convert isAlreadyEgo from boolean|null to boolean
1 parent a43a364 commit 0d19bde

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/SidePanel.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ export default function SidePanel({
112112
const references =
113113
entity && roCrate ? findReferences(roCrate, entity["@id"]) : [];
114114

115-
const isAlreadyEgo = entity && egoNodeId === entity["@id"];
115+
const isAlreadyEgo = !!(entity && egoNodeId === entity["@id"]);
116116

117117
const handleMakeEgo = () => {
118118
if (entity && onMakeEgo) {

0 commit comments

Comments
 (0)