Problem/Motivation
There is a bug in groupmedia_update_8001 which incorrectly determines which bundles to apply tracking_enabled to.
The previous configuration value groupmedia.settings.bundles was a list of bundle to exclude from tracking (https://git.drupalcode.org/project/groupmedia/-/commit/dd92ffbadad1d73a1...)
The update hook incorrectly interprets this as a list of bundles to enable https://git.drupalcode.org/project/groupmedia/-/commit/dd92ffbadad1d73a1...
Steps to reproduce
- Install groupmedia 4.0.0-alpha4
- Add a group & enable media relation for 2 media bundles
- Enable tracking
- Exclude one bundle from the excluded bundles list
- Update to 4.0.0-alpha6 and run updatedb
After the update hook, the excluded bundle has tracking_enabled, but the bundle previously being tracked does not have the value.
Proposed resolution
Get the bundles where tracking is enabled by comparing the list of media bundles and excluding any specified in groupmedia.settings.bundles
Remaining tasks
Review
User interface changes
N/A
API changes
N/A
Data model changes
N/A
| Comment | File | Size | Author |
|---|---|---|---|
| #9 | 3358320-9.patch | 1.33 KB | msnassar |
| #2 | groupmedia-invert-update-hook-3358320-2.patch | 1.37 KB | ericgsmith |
Comments
Comment #2
ericgsmith commentedComment #5
lobsterr commentedYes, my bad. It is completely slipped from my mind that we exclude bundles :(
Thank you for your contribution
Comment #6
ericgsmith commentedNo problem - thanks for the fast commit!
Comment #7
lobsterr commentedI have published new releases with the fix
Comment #8
msnassar commented@LOBsTerr I have encountered the same issue when upgrading from 8.x-2.0-alpha11 to 8.x-2.0-rc2
Comment #9
msnassar commentedHere is a patch for version 8.x-2.0-rc2
Comment #11
lobsterr commented@msnassar Thank you, tagged a new version