correct phpcs config

Signed-off-by: Michael Kaufmann (d00p) <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann (d00p)
2018-02-27 09:30:57 +01:00
parent b46d3a3769
commit b097c19c0a
4 changed files with 43 additions and 34 deletions

View File

@@ -1555,7 +1555,7 @@ class Domains extends ApiCommand implements ResourceEntity
// trigger when domain id for alias destination has changed: both for old and new destination
triggerLetsEncryptCSRForAliasDestinationDomain($result['aliasdomain'], $this->logger());
triggerLetsEncryptCSRForAliasDestinationDomain($aliasdomain, $this->logger());
} else if ($result['wwwserveralias'] != $wwwserveralias || $result['letsencrypt'] != $letsencrypt) {
} elseif ($result['wwwserveralias'] != $wwwserveralias || $result['letsencrypt'] != $letsencrypt) {
// or when wwwserveralias or letsencrypt was changed
triggerLetsEncryptCSRForAliasDestinationDomain($aliasdomain, $this->logger());
}

View File

@@ -83,20 +83,24 @@ class Froxlor extends ApiCommand
/**
*
* @todo import settings
*
*
* @access admin
*/
public function importSettings()
{}
{
throw new Exception("Not available yet.", 501);
}
/**
*
* @todo export settings to file
*
*
* @access admin
*/
public function exportSettings()
{}
{
throw new Exception("Not available yet.", 501);
}
/**
* return a list of all settings
@@ -202,7 +206,7 @@ class Froxlor extends ApiCommand
array_push($functions, array_merge(array(
'module' => $module,
'function' => $func->name
), $this->_getParamListFromDoc($module, $func->name)));
), $this->getParamListFromDoc($module, $func->name)));
}
}
} else {
@@ -234,7 +238,7 @@ class Froxlor extends ApiCommand
array_push($functions, array_merge(array(
'module' => $matches[1],
'function' => $func->name
), $this->_getParamListFromDoc($matches[1], $func->name)));
), $this->getParamListFromDoc($matches[1], $func->name)));
}
}
}
@@ -259,7 +263,7 @@ class Froxlor extends ApiCommand
* @throws Exception
* @return array|bool
*/
private function _getParamListFromDoc($module = null, $function = null)
private function getParamListFromDoc($module = null, $function = null)
{
try {
// set the module
@@ -307,7 +311,8 @@ class Froxlor extends ApiCommand
'type' => $r[1],
'desc' => (isset($r[2]) ? trim($r[2]) : '')
);
} else if (! empty($c) && strpos($c, '@throws') === false) {
}
elseif (! empty($c) && strpos($c, '@throws') === false) {
if (substr($c, 0, 3) == "/**") {
continue;
}
@@ -331,7 +336,7 @@ class Froxlor extends ApiCommand
}
}
}
$result['head'] =trim($result['head']);
$result['head'] = trim($result['head']);
return $result;
} catch (\ReflectionException $e) {
return array();