Commit d9f4b926 authored by Richard Mansfield's avatar Richard Mansfield
Browse files

Show authinstance when creating users even when there's only one

parent 92e4a754
......@@ -89,7 +89,7 @@ if ($USER->get('admin')) {
}
}
if (count($authinstances) > 1) {
if (count($authinstances) > 0) {
$options = array();
$external = false;
......@@ -119,11 +119,6 @@ if (count($authinstances) > 1) {
'description' => get_string('remoteusernamedescription', 'admin'),
);
}
} else if (count($authinstances == 1)) {
$elements['authinstance'] = array(
'type' => 'hidden',
'value' => $authinstances[0]->id,
);
}
$elements['submit'] = array(
......
......@@ -79,7 +79,7 @@ if ($USER->get('admin')) {
}
}
if (count($authinstances) > 1) {
if (count($authinstances) > 0) {
$options = array();
foreach ($authinstances as $authinstance) {
......@@ -97,16 +97,6 @@ if (count($authinstances) > 1) {
'defaultvalue' => $default
);
}
else {
foreach ($authinstances as $authinstance) {
$string = $authinstance->id .'_'. $authinstance->name;
}
$authinstanceelement = array(
'type' => 'hidden',
'value' => $string
);
}
$form = array(
'name' => 'uploadcsv',
......
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