refactoring
This commit is contained in:
parent
96c4b49f06
commit
b6425b9abd
|
@ -405,7 +405,6 @@ class lamList {
|
|||
$table->setCSSClasses(array($scope . '-border accountlist'));
|
||||
$table->setOnClickEvents($onClickEvents);
|
||||
$table->setOnDoubleClickEvents($onDoubleClickEvents);
|
||||
$columnCount = sizeof($titles);
|
||||
|
||||
parseHtml(null, $table, array(), false, $this->tabindex, $scope);
|
||||
}
|
||||
|
|
|
@ -1658,7 +1658,6 @@ class inetOrgPerson extends baseModule implements passwordService {
|
|||
$messages = array();
|
||||
if ($_FILES['photoFile'] && ($_FILES['photoFile']['size'] > 0)) {
|
||||
$name = $_FILES['photoFile']['name'];
|
||||
$extension = strtolower(substr($name, strpos($name, '.') + 1));
|
||||
$handle = fopen($_FILES['photoFile']['tmp_name'], "r");
|
||||
$data = fread($handle, 100000000);
|
||||
if (!empty($this->moduleSettings['inetOrgPerson_jpegPhoto_maxSize'][0]) && (strlen($data) > (1024 * $this->moduleSettings['inetOrgPerson_jpegPhoto_maxSize'][0]))) {
|
||||
|
|
|
@ -5,7 +5,7 @@ use \LAM\PDF\PDFTableRow;
|
|||
/*
|
||||
|
||||
This code is part of LDAP Account Manager (http://www.ldap-account-manager.org/)
|
||||
Copyright (C) 2005 - 2019 Roland Gruber
|
||||
Copyright (C) 2005 - 2020 Roland Gruber
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
|
@ -571,8 +571,6 @@ class ldapPublicKey extends baseModule {
|
|||
* Handles an AJAX file upload and prints the JSON result.
|
||||
*/
|
||||
private function ajaxUpload() {
|
||||
$x = $_GET;
|
||||
$y = $_FILES;
|
||||
$result = array('success' => true);
|
||||
if (!isset($_FILES['qqfile']) || ($_FILES['qqfile']['size'] < 10)) {
|
||||
$result = array('error' => _('No file received.'));
|
||||
|
|
|
@ -483,7 +483,6 @@ class posixAccount extends baseModule implements passwordService {
|
|||
function init($base) {
|
||||
// make optional if needed
|
||||
$modules = $_SESSION[$base]->get_type()->getModules();
|
||||
$typeId = $_SESSION[$base]->get_type()->getId();
|
||||
$this->autoAddObjectClasses = !$this->isOptional($modules) && !$this->skipObjectClass();
|
||||
// call parent init
|
||||
parent::init($base);
|
||||
|
@ -2029,7 +2028,6 @@ class posixAccount extends baseModule implements passwordService {
|
|||
// profile mappings in meta data
|
||||
parent::load_profile($profile);
|
||||
$modules = $this->getAccountContainer()->get_type()->getModules();
|
||||
$typeId = $this->getAccountContainer()->get_type()->getId();
|
||||
// cn
|
||||
if ($this->manageCn($modules) && !empty($profile['posixAccount_cn'][0])) {
|
||||
$this->attributes['cn'][0] = $profile['posixAccount_cn'][0];
|
||||
|
@ -2469,7 +2467,7 @@ class posixAccount extends baseModule implements passwordService {
|
|||
if (self::areGroupOfNamesActive()) {
|
||||
$gons = $this->findGroupOfNames();
|
||||
$gonList = array();
|
||||
foreach ($gons as $dn => $attr) {
|
||||
foreach ($gons as $attr) {
|
||||
$gonList[] = $attr['cn'][0];
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1076,7 +1076,6 @@ class posixGroup extends baseModule implements passwordService {
|
|||
return array();
|
||||
}
|
||||
// auto sync group members
|
||||
$typeId = $this->getAccountContainer()->get_type()->getId();
|
||||
if ($this->isBooleanConfigOptionSet('posixGroup_autoSyncGon')) {
|
||||
$this->syncGon();
|
||||
}
|
||||
|
|
|
@ -592,7 +592,7 @@ class PublicKeyCredentialSourceRepositorySQLite implements PublicKeyCredentialSo
|
|||
logNewMessage(LOG_NOTICE, 'Delete webauthn device ' . $credentialId . ' of ' . $dn);
|
||||
$pdo = $this->getPDO();
|
||||
$statement = $pdo->prepare('delete from ' . self::TABLE_NAME . ' where userId = :userId and credentialId = :credentialId');
|
||||
$result = $statement->execute(array(
|
||||
$statement->execute(array(
|
||||
':userId' => $dn,
|
||||
':credentialId' => $credentialId
|
||||
));
|
||||
|
|
|
@ -22,7 +22,7 @@ use \htmlGroup;
|
|||
/*
|
||||
|
||||
This code is part of LDAP Account Manager (http://www.ldap-account-manager.org/)
|
||||
Copyright (C) 2003 - 2019 Roland Gruber
|
||||
Copyright (C) 2003 - 2020 Roland Gruber
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
|
@ -556,7 +556,6 @@ parseHtml(null, $buttonContainer, array(), false, $tabindex, 'user');
|
|||
*/
|
||||
function checkInput() {
|
||||
$conf = &$_SESSION['conf_config'];
|
||||
$types = $conf->get_ActiveTypes();
|
||||
|
||||
// check new preferences
|
||||
$errors = array();
|
||||
|
|
Loading…
Reference in New Issue