@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | |
41 | 41 | foreach ($acl as $rule) { |
42 | 42 | if (!is_array($rule)) { |
43 | - throw new Error\Exception('Invalid rule in access control list: ' . var_export($rule, true)); |
|
43 | + throw new Error\Exception('Invalid rule in access control list: '.var_export($rule, true)); |
|
44 | 44 | } |
45 | 45 | if (count($rule) === 0) { |
46 | 46 | throw new Error\Exception('Empty rule in access control list.'); |
@@ -49,7 +49,7 @@ discard block |
||
49 | 49 | $action = array_shift($rule); |
50 | 50 | if ($action !== 'allow' && $action !== 'deny') { |
51 | 51 | throw new Error\Exception( |
52 | - 'Invalid action in rule in access control list: ' . var_export($action, true), |
|
52 | + 'Invalid action in rule in access control list: '.var_export($action, true), |
|
53 | 53 | ); |
54 | 54 | } |
55 | 55 | } |
@@ -66,7 +66,7 @@ discard block |
||
66 | 66 | { |
67 | 67 | $config = Configuration::getOptionalConfig('acl.php'); |
68 | 68 | if (!$config->hasValue($id)) { |
69 | - throw new Error\Exception('No ACL with id ' . var_export($id, true) . ' in config/acl.php.'); |
|
69 | + throw new Error\Exception('No ACL with id '.var_export($id, true).' in config/acl.php.'); |
|
70 | 70 | } |
71 | 71 | |
72 | 72 | return $config->getArray($id); |
@@ -129,7 +129,7 @@ discard block |
||
129 | 129 | case 'or': |
130 | 130 | return self::opOr($attributes, $rule); |
131 | 131 | default: |
132 | - throw new Error\Exception('Invalid ACL operation: ' . var_export($op, true)); |
|
132 | + throw new Error\Exception('Invalid ACL operation: '.var_export($op, true)); |
|
133 | 133 | } |
134 | 134 | } |
135 | 135 |
@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | $as->requireAuth(); |
61 | 61 | |
62 | 62 | // User logged in with auth source. |
63 | - Logger::debug('Statistics auth - valid login with auth source [' . $authsource . ']'); |
|
63 | + Logger::debug('Statistics auth - valid login with auth source ['.$authsource.']'); |
|
64 | 64 | |
65 | 65 | // Retrieving attributes |
66 | 66 | $attributes = $as->getAttributes(); |
@@ -74,12 +74,12 @@ discard block |
||
74 | 74 | // Check if userid is allowed access.. |
75 | 75 | if (in_array($attributes[$useridattr][0], $allowedusers, true)) { |
76 | 76 | Logger::debug( |
77 | - 'Statistics auth - User granted access by user ID [' . $attributes[$useridattr][0] . ']', |
|
77 | + 'Statistics auth - User granted access by user ID ['.$attributes[$useridattr][0].']', |
|
78 | 78 | ); |
79 | 79 | return; |
80 | 80 | } |
81 | 81 | Logger::debug( |
82 | - 'Statistics auth - User denied access by user ID [' . $attributes[$useridattr][0] . ']', |
|
82 | + 'Statistics auth - User denied access by user ID ['.$attributes[$useridattr][0].']', |
|
83 | 83 | ); |
84 | 84 | } else { |
85 | 85 | Logger::debug('Statistics auth - no allowedUsers list.'); |
@@ -78,7 +78,7 @@ discard block |
||
78 | 78 | |
79 | 79 | $timeresconfig = $timeresconfigs->getConfigItem($timeres); |
80 | 80 | if ($timeresconfig === null) { |
81 | - throw new Error\ConfigurationError('Missing \'timeres.' . $timeres . '\' in module configuration.'); |
|
81 | + throw new Error\ConfigurationError('Missing \'timeres.'.$timeres.'\' in module configuration.'); |
|
82 | 82 | } |
83 | 83 | |
84 | 84 | $this->timeresconfig = $timeresconfig; |
@@ -359,7 +359,7 @@ discard block |
||
359 | 359 | 'Statistics\FieldPresentation', |
360 | 360 | ); |
361 | 361 | if (!class_exists($classname)) { |
362 | - throw new Exception('Could not find field presentation plugin [' . $classname . ']: No class found'); |
|
362 | + throw new Exception('Could not find field presentation plugin ['.$classname.']: No class found'); |
|
363 | 363 | } |
364 | 364 | $presentationHandler = new $classname($availdelimiters, $fieldpresConfig->getValue('config'), $t); |
365 | 365 | |
@@ -400,17 +400,17 @@ discard block |
||
400 | 400 | $rules = $this->ruleid; |
401 | 401 | foreach ($rules as $rule) { |
402 | 402 | // Get file and extract results. |
403 | - $resultFileName = $statdir . '/' . $rule . '-' . $this->timeres . '-' . $this->fileslot . '.stat'; |
|
403 | + $resultFileName = $statdir.'/'.$rule.'-'.$this->timeres.'-'.$this->fileslot.'.stat'; |
|
404 | 404 | if (!file_exists($resultFileName)) { |
405 | - throw new Exception('Aggregated statitics file [' . $resultFileName . '] not found.'); |
|
405 | + throw new Exception('Aggregated statitics file ['.$resultFileName.'] not found.'); |
|
406 | 406 | } |
407 | 407 | if (!is_readable($resultFileName)) { |
408 | - throw new Exception('Could not read statitics file [' . $resultFileName . ']. Bad file permissions?'); |
|
408 | + throw new Exception('Could not read statitics file ['.$resultFileName.']. Bad file permissions?'); |
|
409 | 409 | } |
410 | 410 | $resultfile = file_get_contents($resultFileName); |
411 | 411 | $newres = unserialize($resultfile); |
412 | 412 | if (empty($newres)) { |
413 | - throw new Exception('Aggregated statistics in file [' . $resultFileName . '] was empty.'); |
|
413 | + throw new Exception('Aggregated statistics in file ['.$resultFileName.'] was empty.'); |
|
414 | 414 | } |
415 | 415 | $resarray[] = $newres; |
416 | 416 | } |