Remove source from media mappings

Created on 25 March 2022, over 2 years ago
Updated 28 April 2024, 8 months ago

Problem/Motivation

When using meta field mappings on an image bundle. Replacing an image fails to save the file resulting in a media object with no file.

Steps to reproduce

  • Install media module
  • Edit the image bundle assigning meta mapping for something other than name (name works)
  • Create an image
  • Edit image by adding a new file.
  • Go back into media to edit and the file is missing

another scenario

  • Create a media object and save with FIleA. Everything in the database populates fine.
  • Edit the media object and add a new File (FileB). The field_image and field_image_revisions tables get no entry. So now it appears the file is missing because the data was never entered.

Resulting in data missing.

Disable field mappings and repeat steps and the file is there.

Proposed resolution

Prevent the 'source' field from being shown in the list of fields available in the mappings
Unset any existing media type mapping using source field

Remaining tasks


Review

User interface changes

Source fields are no longer available in the mapping dropdown

API changes

NA

Data model changes

NA

Release notes snippet

πŸ› Bug report
Status

Fixed

Version

10.3 ✨

Component
MediaΒ  β†’

Last updated 3 days ago

Created by

πŸ‡ΊπŸ‡ΈUnited States smustgrave

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024