Lexical Upload field crashes when using external file storage

default discord avatar
augdust
4 weeks ago

Hey all!



I recently got my external cloud file storage set up, but that made my Collection with a Lexical Rich Text field crash the collection.



The error I get whenever I try to load the collection is as follows:



[08:51:55] ERROR (payload): TypeError: Cannot read properties of undefined (reading 'payload')
    at promise (/project-dir/node_modules/@payloadcms/richtext-lexical/src/field/features/Upload/afterReadPromise.ts:25:30)
    at forEach (/project-dir/node_modules/@payloadcms/richtext-lexical/src/populate/richTextRelationshipPromise.ts:45:16)
    at Array.forEach (<anonymous>)
    at recurseRichText (/project-dir/node_modules/@payloadcms/richtext-lexical/src/populate/richTextRelationshipPromise.ts:41:14)
    at richTextRelationshipPromise (/project-dir/node_modules/@payloadcms/richtext-lexical/src/populate/richTextRelationshipPromise.ts:90:3)
    at Object.afterReadPromise (/project-dir/node_modules/@payloadcms/richtext-lexical/src/index.ts:70:43)
    at promise (/project-dir/node_modules/payload/src/fields/hooks/afterRead/promise.ts:157:42)
    at forEach (/project-dir/node_modules/payload/src/fields/hooks/afterRead/traverseFields.ts:45:14)
    at Array.forEach (<anonymous>)
    at traverseFields (/project-dir/node_modules/payload/src/fields/hooks/afterRead/traverseFields.ts:43:10)

The collection page loads, but it just shows an infinite skeleton loader for the collection items.



Running Payload 2.0.14



tried disabling the cloudstorage-plugin, and I'm still receiving the error from my previous message

:shrugok:


fixed it by updating the lexical-plugin, cloud-storage-plugin and deleting 'node_modules' and doing a fresh 'yarn install' :)

    Open the post
    Continue the discussion in Discord
    Like what we're doing?
    Star us on GitHub!

    Star

    Connect with the Payload Community on Discord

    Discord

    online

    Can't find what you're looking for?

    Get help straight from the Payload team with an Enterprise License.