Removing the Admin Account from an institution is producing warning

Bug #1908845 reported by Lisa Seeto
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
20.04
Fix Released
High
Doris Tam
20.10
Fix Released
High
Doris Tam
21.04
Fix Released
High
Lisa Seeto

Bug Description

A warning is being produced when the Admin Account is removed from an institution via the admin/users/edit.php page:

[WAR] af (lib/pieforms/pieform.php:1424) Invalid value for select "authinstance"
Call stack (most recent first):

    log_message("Invalid value for select "authinstance"", 8, true, true, "/home/lisaseeto/code/mahara-catalyst/htdocs/lib/pi...", 1424) at /home/lisaseeto/code/mahara-catalyst/htdocs/lib/errors.php:515
    error(1024, "Invalid value for select "authinstance"", "/home/lisaseeto/code/mahara-catalyst/htdocs/lib/pi...", 1424, array(size 1)) at Unknown:0
    trigger_error("Invalid value for select "authinstance"", 1024) at /home/lisaseeto/code/mahara-catalyst/htdocs/lib/pieforms/pieform.php:1424
    Pieform::info("Invalid value for select "authinstance"") at /home/lisaseeto/code/mahara-catalyst/htdocs/lib/pieforms/pieform/elements/select.php:152
    pieform_element_select(object(Pieform), array(size 12)) at /home/lisaseeto/code/mahara-catalyst/htdocs/lib/pieforms/pieform.php:1601
    Pieform->build_element_html(array(size 12)) at /home/lisaseeto/code/mahara-catalyst/htdocs/lib/pieforms/pieform.php:762
    Pieform->build() at /home/lisaseeto/code/mahara-catalyst/htdocs/lib/pieforms/pieform.php:173
    Pieform::process(array(size 6)) at /home/lisaseeto/code/mahara-catalyst/htdocs/lib/mahara.php:5507
    pieform(array(size 6)) at /home/lisaseeto/code/mahara-catalyst/htdocs/admin/users/edit.php:343

Steps to test:
1. Log into site as Admin Account.
2. On site options -> Institution settings have "People allowed multiple institutions" set to 'No'
3. For the "No institution" (mahara) inst. settings have 'Authentication plugin' as 'Internal', 'Web services'
4. Navigate to the admin/users/edit.php page for Admin Account (this can be done via People search)
5. Add the account to an institution, then without refreshing the page, remove the account from that institution.
Expected results:
Only the session messages are returned.
Actual results:
A warning message is returned along with session messages.

Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "master" branch: https://reviews.mahara.org/11506

Lisa Seeto (lisaseeto)
Changed in mahara:
assignee: nobody → Lisa Seeto (lisaseeto)
status: New → In Progress
Changed in mahara:
milestone: none → 21.04.0
importance: Undecided → High
Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/11506
Committed: https://git.mahara.org/mahara/mahara/commit/8a12f7784eec89001723a93bc90eb9b1e361db8b
Submitter: Robert Lyon (<email address hidden>)
Branch: master

commit 8a12f7784eec89001723a93bc90eb9b1e361db8b
Author: Lisa Seeto <email address hidden>
Date: Mon Dec 21 15:33:01 2020 +1300

Bug 1908845: Removing the Admin Account from an institution is producing warning

- set the user->authinstance in removeMember()

Change-Id: I34afd54149936b02b61d65cc036c0a2d4450f576
Signed-off-by: Lisa Seeto <email address hidden>

Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "20.10_STABLE" branch: https://reviews.mahara.org/11548

Revision history for this message
Mahara Bot (dev-mahara) wrote :

Patch for "20.04_STABLE" branch: https://reviews.mahara.org/11549

Revision history for this message
Mahara Bot (dev-mahara) wrote :

Patch for "19.10_STABLE" branch: https://reviews.mahara.org/11550

no longer affects: mahara/19.10
Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/11548
Committed: https://git.mahara.org/mahara/mahara/commit/f28f2b92b38e9866c18522142d13ef0ff6edff40
Submitter: Robert Lyon (<email address hidden>)
Branch: 20.10_STABLE

commit f28f2b92b38e9866c18522142d13ef0ff6edff40
Author: Lisa Seeto <email address hidden>
Date: Mon Dec 21 15:33:01 2020 +1300

Bug 1908845: Removing the Admin Account from an institution is producing warning

- set the user->authinstance in removeMember()

Change-Id: I34afd54149936b02b61d65cc036c0a2d4450f576
Signed-off-by: Lisa Seeto <email address hidden>
(cherry picked from commit 8a12f7784eec89001723a93bc90eb9b1e361db8b)

Revision history for this message
Mahara Bot (dev-mahara) wrote :

Reviewed: https://reviews.mahara.org/11549
Committed: https://git.mahara.org/mahara/mahara/commit/68ad52e277b8529aeb9c534ffaebd8aa80a0f695
Submitter: Robert Lyon (<email address hidden>)
Branch: 20.04_STABLE

commit 68ad52e277b8529aeb9c534ffaebd8aa80a0f695
Author: Lisa Seeto <email address hidden>
Date: Mon Dec 21 15:33:01 2020 +1300

Bug 1908845: Removing the Admin Account from an institution is producing warning

- set the user->authinstance in removeMember()

Change-Id: I34afd54149936b02b61d65cc036c0a2d4450f576
Signed-off-by: Lisa Seeto <email address hidden>
(cherry picked from commit 8a12f7784eec89001723a93bc90eb9b1e361db8b)

no longer affects: mahara
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.