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

Unexpected "media" and other keys in Image field value #318

Closed
JarJak opened this issue Feb 7, 2019 · 1 comment
Closed

Unexpected "media" and other keys in Image field value #318

JarJak opened this issue Feb 7, 2019 · 1 comment
Labels
topic: API All issues dealing with API-Platform topic: Media

Comments

@JarJak
Copy link
Member

JarJak commented Feb 7, 2019

Summary:

Saving Image field adds some extra fields, like "media" or "title". I don't know where they came from.

Steps to reproduce:

Through admin panel, save record with image field filled.
Then call dump(record.image)

Expected result:

{
  "filename": "kitten.jpg",
  "alt": "A cute kitten",
  "path": "/thumbs/kitten.jpg?w=240&h=160&area=files"
}

Actual result:

{
  "media": "",
  "filename": "kitten.jpg",
  "alt": "A cute kitten",
  "title": "",
   "0": "",
  "path": "/thumbs/kitten.jpg?w=240&h=160&area=files"
}
@JarJak JarJak added this to the Bolt 4.0.0 stable milestone Apr 3, 2019
@JarJak JarJak added topic: API All issues dealing with API-Platform topic: Media labels Apr 14, 2019
@bobdenotter
Copy link
Member

Closing old issue.. Will be fixed (for now) in the upcoming changes to image.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: API All issues dealing with API-Platform topic: Media
Projects
None yet
Development

No branches or pull requests

2 participants