Incorrect "not assigned to group" debug log

Created on 8 February 2023, about 2 years ago
Updated 2 March 2023, about 2 years ago

Problem/Motivation

When media is added to a group, a Drupal log is added that says "Media [MEDIA NAME] (MEDIA ID) was not assigned to group [GROUP NAME] because max group cardinality was reached". The severity of the log is Debug. The log is incorrect. The media is added to the group and is visible at /group/[GROUP ID]/media.

Steps to reproduce

  • Enable this module.
  • Enable the core dblog module.
  • Enable a media type/bundle as group content for a group type at /admin/group/types/manage/[GROUP TYPE]/content. Set the cardinality to 1.
  • Enable tracking for this media bundle /admin/group/settings/media.
  • Give your current user group level permissions to create media in the group type at /admin/group/types/manage/[GROUP TYPE]/permissions.
  • Create new media using the Create media button at /group/[GROUP ID]/media.
  • You will see the media created successfully. Go back to /group/[GROUP ID]/media. You will see the media you just created in the view.
  • Go to /admin/reports/dblog?type%5B%5D=groupmedia . You will see a log as described above.

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

πŸ› Bug report
Status

Fixed

Version

2.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States maskedjellybean Portland, OR

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

Comments & Activities

Production build 0.71.5 2024