fix: Account for createdBy, updatedBy being undefined. closes #6578

This commit is contained in:
Tom Moor
2024-02-26 21:55:06 -05:00
parent 7e4b60df4d
commit edae1c6ee1
7 changed files with 10 additions and 10 deletions

View File

@@ -97,7 +97,7 @@ function DocumentListItem(
highlight={highlight}
dir={document.dir}
/>
{document.isBadgedNew && document.createdBy.id !== user.id && (
{document.isBadgedNew && document.createdBy?.id !== user.id && (
<Badge yellow>{t("New")}</Badge>
)}
{canStar && (

View File

@@ -81,7 +81,7 @@ export const OtherAccess = observer(({ document, children }: Props) => {
<>
<StyledListItem
image={<Avatar model={document.createdBy} showBorder={false} />}
title={document.createdBy.name}
title={document.createdBy?.name}
actions={
<AccessTooltip content={t("Created the document")}>
{t("Can edit")}