api endpoint student: prevent storing an empty string as alias e.g. from StudVw Details Tab

This commit is contained in:
Harald Bamberger
2026-01-15 17:09:30 +01:00
parent c720c46125
commit ef08e39449
@@ -321,6 +321,10 @@ class Student extends FHCAPI_Controller
foreach ($array_allowed_props_benutzer as $prop) {
$val = $this->input->post($prop);
if ($val !== null) {
if($prop === 'alias' && $val === '')
{
$val = null;
}
$update_benutzer[$prop] = $val;
}
}