You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When blocks are nested in a collection with localization enabled, it gives an error when saving the block on more than 1 locale.
I've only experienced this error with Postgres.
I get the following error in the console:
ERROR (payload): TypeError: Cannot read properties of undefined (reading 'categories_blocks_widget_pkey')
at upsertRow (C:\git\payload-block-test\node_modules\@payloadcms\db-postgres\src\upsertRow\index.ts:318:57)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
at Object.updateOne (C:\git\payload-block-test\node_modules\@payloadcms\db-postgres\src\update.ts:44:18)
at updateByID (C:\git\payload-block-test\node_modules\payload\src\collections\operations\updateByID.ts:273:16)
at updateByIDHandler (C:\git\payload-block-test\node_modules\payload\src\collections\requestHandlers\updateByID.ts:43:17)
I run a postgres db with the following docker compose:
Create a new category with a row and a widget, click save draft and publish afterwards.
Now go to the second locale on the same category and add a row and a widget again and click save draft and publish. An error will be thrown when clicking publish.
Payload Version
2.22.2
Adapters and Plugins
db-postgres
The text was updated successfully, but these errors were encountered:
Link to reproduction
https://github.com/PeterRygeBestseller/payload-block-test
Describe the Bug
When blocks are nested in a collection with localization enabled, it gives an error when saving the block on more than 1 locale.
I've only experienced this error with Postgres.
I get the following error in the console:
I run a postgres db with the following docker compose:
To Reproduce
Create a new category with a row and a widget, click save draft and publish afterwards.
Now go to the second locale on the same category and add a row and a widget again and click save draft and publish. An error will be thrown when clicking publish.
Payload Version
2.22.2
Adapters and Plugins
db-postgres
The text was updated successfully, but these errors were encountered: