Fixed rebuildUserGroupRelations & group id = 0

Xon

Well-known member
Affected version
2.2.13
I recently ran into a case where a customer's forum had a 0 in xf_user.secondary_group_ids (specifically just '0' as the value). This has resulting in rows of xf_user_group_relation.user_group_id having the value of 0.

I've got no idea how this data got in there, but rebuildUserGroupRelations doesn't handle this edge case. This makes joining/using xf_user_group_relation difficult as it can have unexpected data in it.
 
Thank you for reporting this issue, it has now been resolved. We are aiming to include any changes that have been made in a future XF release (2.2.14).

Change log:
When rebuilding user group relations, skip falsey values
There may be a delay before changes are rolled out to the XenForo Community.
 
Back
Top Bottom