diff --git a/packages/text-editor/src/provider/storage.ts b/packages/text-editor/src/provider/storage.ts index 76863997ce..80e77f1e29 100644 --- a/packages/text-editor/src/provider/storage.ts +++ b/packages/text-editor/src/provider/storage.ts @@ -40,7 +40,7 @@ async function fetchContent (blob: Ref, doc: YDoc): Promise { async function fetchBlobContent (_id: Ref): Promise { try { const blob = (await getClient().findOne(core.class.Blob, { _id })) as BlobLookup - if (blob?.size === 0) { + if (blob === undefined || blob.size === 0) { return undefined } const href = await getBlobHref(blob, _id)