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

Comments

@JarJak
Copy link
Member

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"
}
@bobdenotter

This comment has been minimized.

Copy link
Member

commented Jul 25, 2019

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
Projects
None yet
2 participants
You can’t perform that action at this time.