Skip to content
This repository was archived by the owner on Feb 3, 2026. It is now read-only.

fix: added prop & check for readonly status of the document#109

Merged
richhiggins merged 2 commits intomainfrom
fix/attempted-to-patch-a-read-only-document
Dec 9, 2025
Merged

fix: added prop & check for readonly status of the document#109
richhiggins merged 2 commits intomainfrom
fix/attempted-to-patch-a-read-only-document

Conversation

@richhiggins
Copy link
Contributor

@richhiggins richhiggins commented Dec 9, 2025

Description

Fixes a bug where a patch is attempted when creating a new document and the document is not in an editable state resulting in error message Attempted to patch a read-only document.

Adds a readonly prop & checks for the readonly status of the current document.

What to review

Added prop:
https://github.com/sanity-io/sanity-plugin-internationalized-array/pull/109/files#diff-d3dc0e2098712407c1b56260dd28c115ed41e34a1ebac935b86887f19292e263R38

Added check:
https://github.com/sanity-io/sanity-plugin-internationalized-array/pull/109/files#diff-d3dc0e2098712407c1b56260dd28c115ed41e34a1ebac935b86887f19292e263R128

Testing

Tested manually in local studio v4.20.3.

@richhiggins richhiggins requested a review from stipsan December 9, 2025 15:01
@richhiggins richhiggins merged commit 4469ef1 into main Dec 9, 2025
9 checks passed
@richhiggins richhiggins deleted the fix/attempted-to-patch-a-read-only-document branch December 9, 2025 15:46
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants