Skip to:
Content

BuddyPress.org

Opened 2 months ago

Closed 2 weeks ago

#9223 closed defect (bug) (fixed)

Inconsistency in Groups WP Admin feedback messages

Reported by: martenw's profile martenw Owned by: imath's profile imath
Milestone: 15.0.0 Priority: normal
Severity: normal Version: 14.0.0
Component: Groups Keywords: has-patch
Cc:

Description

After removing a member from a group a success as well as an error is reported.
The reason for this is a missing return statement with the value TRUE at the end of the function groups_remove_member() in the file bp-groups-functions.php.

The second message reported after adding the mentioned return statement is not logical to me.

The group has been updated successfully.
The following members were successfully modified: xxx

The member isn’t modified but removed from the group.

Change History (9)

#1 @imath
2 months ago

  • Keywords needs-patch added
  • Milestone changed from Awaiting Review to 14.1.0

Hi @martenw

Thanks a lot for your report. I confirm the issue. It's happening when the BP REST API based UI to manage members is not available (eg: the BP Legacy template pack is used instead of the BP Nouveau one). In this case we fall back to the legacy UI / Admin functions.

On front-end, an error message is thrown although the members was removed.
On back-end, @martenw's description is accurate.

The root cause is a regression I introduced in r13873 during the 14.0 development cycle. I forgot to return true at the end of the groups_remove_member() function as @martenw noted.

I'll work on a fix asap.

This ticket was mentioned in PR #356 on buddypress/buddypress by @imath.


2 months ago
#2

  • Keywords has-patch added; needs-patch removed

This PR specifically targets milestone 14.1: it's only making sure feedback messages when using the BP Legacy template pack are not totally misleading when a member is removed from a group.

The Group's Admin UI, once this PR is committed, will need to be improved to better reflect the kind of action that was performed for a specific member of the group instead of simply grouping everything into "modification".

Trac ticket: https://buddypress.trac.wordpress.org/ticket/9223

#3 @imath
2 months ago

  • Summary changed from Inconsistency is messages to Inconsistency in Groups WP Admin feedback messages

#4 @imath
2 months ago

In 13996:

Groups: avoid misleading feedback messages on group members removal

Make sure to return true when a member is removed from a group. This is regression introduced in r13873.

Props martenw

See #9223 (trunk)
Closes https://github.com/buddypress/buddypress/pull/356

#5 @imath
2 months ago

  • Owner set to imath
  • Resolution set to fixed
  • Status changed from new to closed

In 13997:

Groups: avoid misleading feedback messages on group members removal

Make sure to return true when a member is removed from a group. This is regression introduced in r13873.

Props martenw

Fixes #9223 (branch 14.0)

#6 @imath
2 months ago

  • Keywords has-patch removed
  • Milestone changed from 14.1.0 to 15.0.0
  • Resolution fixed deleted
  • Status changed from closed to reopened

I'm reopening this ticket to work on the second part during 15.0.0:

The Group's Admin UI, once this PR is committed, will need to be improved to better reflect the kind of action that was performed for a specific member of the group instead of simply grouping everything into "modification".

This ticket was mentioned in Slack in #buddypress by espellcaste. View the logs.


3 weeks ago

This ticket was mentioned in PR #374 on buddypress/buddypress by @imath.


3 weeks ago
#8

  • Keywords has-patch added

-> Use multidimensional arrays to bring more meaningful user feecbacks.

Trac ticket: https://buddypress.trac.wordpress.org/ticket/9223

#9 @imath
2 weeks ago

  • Resolution set to fixed
  • Status changed from reopened to closed

In 14024:

Groups Admin: improve feedback messages after group edits

In particular use more meaningful confirmation/error messages when a group member is promoted, demoted, banned, removed or when a user is added to the group.

Props martenw

Fixes #9223
Closes https://github.com/buddypress/buddypress/pull/374

Note: See TracTickets for help on using tickets.