Commit a1570291 authored by Richard Mansfield's avatar Richard Mansfield

Don't expect remote username to be set when editing user accounts

parent 97194d3f
......@@ -215,8 +215,9 @@ function edituser_site_submit(Pieform $form, $values) {
if (!$remotename) {
$remotename = $user->username;
}
if (isset($values['authinstance']) && ($values['authinstance'] != $user->authinstance
|| $values['remoteusername'] != $remotename)) {
if (isset($values['authinstance'])
&& ($values['authinstance'] != $user->authinstance
|| (isset($values['remoteusername']) && $values['remoteusername'] != $remotename))) {
$authinst = get_records_select_assoc('auth_instance', 'id = ? OR id = ?',
array($values['authinstance'], $user->authinstance));
if ($USER->get('admin') ||
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment