diff --git a/lam/lib/account.inc b/lam/lib/account.inc index 26581533d..cf243b34e 100644 --- a/lam/lib/account.inc +++ b/lam/lib/account.inc @@ -985,7 +985,7 @@ function searchLDAPPaged($server, $dn, $filter, $attributes, $attrsOnly, $limit) * * @param String $dn DN * @param array $attributes list of attributes to fetch - * @param handle $handle LDAP handle (optional for admin interface pages) + * @param Connection $handle LDAP handle (optional for admin interface pages) * @return ?array attributes or null if not found */ function ldapGetDN($dn, $attributes = ['dn'], $handle = null): ?array { @@ -2008,8 +2008,8 @@ function formatSecondsToShortFormat($numSeconds) { /** * Unformats text like 1m10s back to number of seconds. * - * @param String $text formatted text - * @return int number of seconds + * @param string $text formatted text + * @return int|string number of seconds */ function unformatShortFormatToSeconds($text) { if (empty($text)) { diff --git a/lam/lib/modules.inc b/lam/lib/modules.inc index 76ad85a07..877ed7840 100644 --- a/lam/lib/modules.inc +++ b/lam/lib/modules.inc @@ -2446,8 +2446,8 @@ interface passwordService { * This function is called whenever the password should be changed. Account modules * must change their password attributes only if the modules list contains their module name. * - * @param String $password new password - * @param array $modules list of modules for which the password should be changed + * @param string $password new password + * @param string[] $modules list of modules for which the password should be changed * @param boolean $forcePasswordChange force the user to change his password at next login * @return array list of error messages if any as parameter array for StatusMessage * e.g. return array(array('ERROR', 'Password change failed.')) @@ -2542,7 +2542,7 @@ interface AccountStatusProvider { * Returns the list of account status detail lines. * * @param ConfiguredType $type account type - * @param array|string>|null $attributes LDAP attributes (use account container attributes if not provided) + * @param array|null $attributes LDAP attributes (use account container attributes if not provided) * @return AccountStatusDetails[] status details */ public function getAccountStatusDetails(ConfiguredType $type, ?array &$attributes): array; @@ -2559,7 +2559,7 @@ interface AccountStatusProvider { * Returns a list of options how the account could be locked. * * @param ConfiguredType $type type - * @param array|string>|null $attributes LDAP attributes + * @param array|null $attributes LDAP attributes * @return AccountStatusDetails[] lock options */ public function getAccountStatusPossibleLockOptions(ConfiguredType $type, ?array &$attributes): array; @@ -2568,7 +2568,7 @@ interface AccountStatusProvider { * Locks the account with the given lock IDs. * * @param ConfiguredType $type type - * @param array|string>|null $attributes LDAP attributes + * @param array|null $attributes LDAP attributes * @param array $lockIds IDs from AccountStatusDetails * @throws LAMException error during locking */ @@ -2578,7 +2578,7 @@ interface AccountStatusProvider { * Unlocks the account with the given lock IDs. * * @param ConfiguredType $type type - * @param array|string>|null $attributes LDAP attributes + * @param array|null $attributes LDAP attributes * @param array $lockIds IDs from AccountStatusDetails */ public function accountStatusPerformUnlock(ConfiguredType $type, ?array &$attributes, array $lockIds): void; diff --git a/lam/templates/lib/500_lam.js b/lam/templates/lib/500_lam.js index d48155709..8da115930 100644 --- a/lam/templates/lib/500_lam.js +++ b/lam/templates/lib/500_lam.js @@ -28,12 +28,7 @@ window.lam = window.lam || {}; */ function list_click(box) { var cbox = document.getElementsByName(box)[0]; - if (cbox.checked) { - cbox.checked = false; - } - else { - cbox.checked = true; - } + cbox.checked = !cbox.checked; } /** @@ -323,7 +318,7 @@ async function confirmLoadProfile(title, text, okText, cancelText, e) { selectValue.value = selectedProfile; form.appendChild(selectValue); form.submit(); - }; + } if (e.preventDefault) { e.preventDefault(); } @@ -1353,7 +1348,7 @@ window.lam.tools.webcam.init = function() { if (mediaDevice.kind === 'videoinput') { contentDiv.classList.remove('hidden'); } - }; + } }); } }; @@ -1901,7 +1896,6 @@ window.lam.webauthn.run = function(prefix, isSelfService, newDeviceNameTitle, ne hiddenSkip.value = 'skip'; form.appendChild(hiddenSkip); form.submit(); - return; }; } const token = document.getElementById('sec_token').value; @@ -2923,7 +2917,7 @@ window.lam.treeview.updatePossibleNewAttributes = function(tokenName, tokenValue option.value = data[attributeName]; option.innerText = attributeName; select.appendChild(option); - }; + } window.lam.treeview.updatePossibleNewAttributesRequest = null; }); } @@ -3698,7 +3692,7 @@ window.lam.config.updateModuleFilter = function(inputField) { if (cell.innerText.toLowerCase().includes(filterValue)) { matches = true; } - }; + } if (matches) { row.classList.remove('hidden'); }