Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes: #17070 - Make image_width and image_height read_only on REST API ImageAttachmentSerializer #17234

Merged

Conversation

bctiemann
Copy link
Contributor

Fixes: #17070 - Make image_width and image_height read_only on REST API ImageAttachmentSerializer

Sets the image_width and image_height fields on ImageAttachmentSerializer to read_only. This prevents redundant and cumbersome "field required" errors when submitting an Image Attachment via the REST API.

Tested to verify that submitting an image via the API without these fields in the payload is still handled correctly via Django and the fields are automatically populated.

@bctiemann bctiemann self-assigned this Aug 21, 2024
@bctiemann bctiemann added the type: feature Introduction of new functionality to the application label Aug 21, 2024
@jeremystretch jeremystretch merged commit 85f8364 into develop Aug 22, 2024
6 checks passed
@jeremystretch jeremystretch deleted the 17070-rest-api-make-image-width-height-read-only branch August 22, 2024 14:59
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 22, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: feature Introduction of new functionality to the application
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remove requirement for image dimensions in API
2 participants