Information Required ? Pending

User tests: Successful: Unsuccessful:

avatar joeforjoomla
joeforjoomla
12 May 2020

The addUserToGroup doesn't work because the 'whereIn' method in Joomla\CMS\Table\User->bind() uses prepared statements based on zero-indexed array

Testing Instructions

Use the function UserHelper addUserToGroup with a user ID and a user group ID

Expected result

The user is assigned to the group

Actual result

The user is not assigned to the group

Documentation Changes Required

Nope

avatar joeforjoomla joeforjoomla - open - 12 May 2020
avatar joeforjoomla joeforjoomla - change - 12 May 2020
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 12 May 2020
Category Libraries
avatar joeforjoomla joeforjoomla - change - 12 May 2020
Title
UserHelper addUserToGroup not working
[4.0]UserHelper addUserToGroup not working
avatar joeforjoomla joeforjoomla - edited - 12 May 2020
avatar alikon alikon - test_item - 13 May 2020 - Tested successfully
avatar alikon
alikon - comment - 13 May 2020

I have tested this item successfully on d832dbf

i've tested with the cli command
php cli/joomla.php user:addtogroup --username aaaa --group Manager


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/29048.
avatar SharkyKZ
SharkyKZ - comment - 21 May 2020

Why not do this in Joomla\CMS\Table\User::bind() instead?

avatar wilsonge wilsonge - change - 29 May 2020
Labels Added: Information Required ?
avatar wilsonge wilsonge - change - 29 May 2020
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2020-05-29 23:41:00
Closed_By wilsonge
avatar wilsonge wilsonge - close - 29 May 2020
avatar wilsonge wilsonge - merge - 29 May 2020
avatar wilsonge
wilsonge - comment - 29 May 2020

I think doing it here is fine. Thanks!

Add a Comment

Login with GitHub to post a comment