mirror of
https://github.com/LDAPAccountManager/lam.git
synced 2025-10-03 01:39:33 +02:00
#451 PHPStan level 5
This commit is contained in:
parent
4c8f3434fc
commit
3c005187ea
2 changed files with 6 additions and 14 deletions
|
@ -5277,8 +5277,8 @@ if (interface_exists('\LAM\JOB\Job', false)) {
|
|||
/**
|
||||
* Returns if the job should run.
|
||||
*
|
||||
* @param $pdo PDO
|
||||
* @param $jobId job id
|
||||
* @param PDO $pdo PDO
|
||||
* @param string $jobId job id
|
||||
* @param DateTime $baseDate base date
|
||||
* @param int $monthInterval month interval
|
||||
* @return bool should run
|
||||
|
@ -5512,15 +5512,7 @@ if (interface_exists('\LAM\JOB\Job', false)) {
|
|||
}
|
||||
|
||||
/**
|
||||
* Checks if a user is expired.
|
||||
*
|
||||
* @param integer $jobID job ID
|
||||
* @param array $options job settings
|
||||
* @param PDO $pdo PDO
|
||||
* @param DateTime $now current time
|
||||
* @param array $policyOptions list of policy options by getPolicyOptions()
|
||||
* @param array $user user attributes
|
||||
* @param boolean $isDryRun just do a dry run, nothing is modified
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
protected function checkSingleUser($jobID, $options, &$pdo, $now, $policyOptions, $user, $isDryRun) {
|
||||
$seconds = substr($user['accountexpires'][0], 0, -7);
|
||||
|
|
|
@ -342,7 +342,7 @@ class ConfigDataImporter {
|
|||
$steps[] = new ImporterStep(_('General settings'), 'mainConfig', $value);
|
||||
break;
|
||||
case 'certificates':
|
||||
$steps[] = new ImporterStep(_('SSL certificates'), 'certificates', $value);
|
||||
$steps[] = new ImporterStep(_('SSL certificates'), 'certificates', [$value]);
|
||||
break;
|
||||
case 'serverProfiles':
|
||||
$mainStep = new ImporterStep(_('Server profiles'), 'serverProfiles', $value);
|
||||
|
@ -424,7 +424,7 @@ class ConfigDataImporter {
|
|||
* Runs the actual import.
|
||||
*
|
||||
* @param ImporterStep[] $steps import steps
|
||||
* @throws LAMException if error occurred
|
||||
* @throws LAMException if an error occurred
|
||||
*/
|
||||
public function runImport($steps) {
|
||||
foreach ($steps as $step) {
|
||||
|
@ -434,7 +434,7 @@ class ConfigDataImporter {
|
|||
$key = $step->getKey();
|
||||
match ($key) {
|
||||
'mainConfig' => $this->importMainConfig($step->getValue()),
|
||||
'certificates' => $this->importCertificates($step->getValue()),
|
||||
'certificates' => $this->importCertificates($step->getValue()[0]),
|
||||
'serverProfiles' => $this->importServerProfiles($step),
|
||||
'accountProfiles' => $this->importAccountProfiles($step),
|
||||
'accountProfileTemplates' => $this->importAccountProfileTemplates($step),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue