@@ -150,7 +150,7 @@ |
||
150 | 150 | } elseif ($checkClass instanceof EnvironmentCheck) { |
151 | 151 | $output[] = [$checkClass, $checkTitle]; |
152 | 152 | } else { |
153 | - throw new InvalidArgumentException("Bad EnvironmentCheck: " . var_export($check, true)); |
|
153 | + throw new InvalidArgumentException("Bad EnvironmentCheck: ".var_export($check, true)); |
|
154 | 154 | } |
155 | 155 | } |
156 | 156 | return $output; |
@@ -32,8 +32,8 @@ |
||
32 | 32 | public function check() |
33 | 33 | { |
34 | 34 | if (function_exists($this->functionName)) { |
35 | - return [EnvironmentCheck::OK, $this->functionName . '() exists']; |
|
35 | + return [EnvironmentCheck::OK, $this->functionName.'() exists']; |
|
36 | 36 | } |
37 | - return [EnvironmentCheck::ERROR, $this->functionName . '() doesn\'t exist']; |
|
37 | + return [EnvironmentCheck::ERROR, $this->functionName.'() doesn\'t exist']; |
|
38 | 38 | } |
39 | 39 | } |
@@ -67,7 +67,7 @@ discard block |
||
67 | 67 | public function __construct($path, $fileTypeValidateFunc = 'noVidation', $checkType = null) |
68 | 68 | { |
69 | 69 | $this->path = $path; |
70 | - $this->fileTypeValidateFunc = ($fileTypeValidateFunc)? $fileTypeValidateFunc : 'noVidation'; |
|
70 | + $this->fileTypeValidateFunc = ($fileTypeValidateFunc) ? $fileTypeValidateFunc : 'noVidation'; |
|
71 | 71 | $this->checkType = ($checkType) ? $checkType : self::CHECK_SINGLE; |
72 | 72 | } |
73 | 73 | |
@@ -100,7 +100,7 @@ discard block |
||
100 | 100 | if ($this->checkType == self::CHECK_SINGLE && count($invalidFiles) < count($files)) { |
101 | 101 | $validFileList = PHP_EOL; |
102 | 102 | foreach ($validFiles as $vf) { |
103 | - $validFileList .= $vf . PHP_EOL; |
|
103 | + $validFileList .= $vf.PHP_EOL; |
|
104 | 104 | } |
105 | 105 | if ($fileTypeValidateFunc == 'noVidation') { |
106 | 106 | $checkReturn = [ |
@@ -123,7 +123,7 @@ discard block |
||
123 | 123 | } else { |
124 | 124 | $invalidFileList = PHP_EOL; |
125 | 125 | foreach ($invalidFiles as $vf) { |
126 | - $invalidFileList .= $vf . PHP_EOL; |
|
126 | + $invalidFileList .= $vf.PHP_EOL; |
|
127 | 127 | } |
128 | 128 | |
129 | 129 | if ($fileTypeValidateFunc == 'noVidation') { |
@@ -144,7 +144,7 @@ discard block |
||
144 | 144 | } |
145 | 145 | } |
146 | 146 | } else { |
147 | - $checkReturn = array( |
|
147 | + $checkReturn = array( |
|
148 | 148 | EnvironmentCheck::ERROR, |
149 | 149 | sprintf("Invalid file type validation method name passed: %s ", $fileTypeValidateFunc) |
150 | 150 | ); |
@@ -96,7 +96,7 @@ |
||
96 | 96 | */ |
97 | 97 | public function check() |
98 | 98 | { |
99 | - $cutoffTime = strtotime($this->relativeAge, DBDatetime::now()->Format('U')); |
|
99 | + $cutoffTime = strtotime($this->relativeAge, DBDatetime::now()->Format('U')); |
|
100 | 100 | $files = $this->getFiles(); |
101 | 101 | $invalidFiles = []; |
102 | 102 | $validFiles = []; |
@@ -32,8 +32,8 @@ |
||
32 | 32 | public function check() |
33 | 33 | { |
34 | 34 | if (class_exists($this->className)) { |
35 | - return [EnvironmentCheck::OK, 'Class ' . $this->className.' exists']; |
|
35 | + return [EnvironmentCheck::OK, 'Class '.$this->className.' exists']; |
|
36 | 36 | } |
37 | - return [EnvironmentCheck::ERROR, 'Class ' . $this->className.' doesn\'t exist']; |
|
37 | + return [EnvironmentCheck::ERROR, 'Class '.$this->className.' doesn\'t exist']; |
|
38 | 38 | } |
39 | 39 | } |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | if ($this->path[0] == '/') { |
35 | 35 | $filename = $this->path; |
36 | 36 | } else { |
37 | - $filename = BASE_PATH . DIRECTORY_SEPARATOR . str_replace('/', DIRECTORY_SEPARATOR, $this->path); |
|
37 | + $filename = BASE_PATH.DIRECTORY_SEPARATOR.str_replace('/', DIRECTORY_SEPARATOR, $this->path); |
|
38 | 38 | } |
39 | 39 | |
40 | 40 | if (file_exists($filename)) { |
@@ -67,8 +67,8 @@ discard block |
||
67 | 67 | } |
68 | 68 | if ($groupList) { |
69 | 69 | $message .= " We recommend that you make the file group-writeable and change the group to " |
70 | - . "one of these groups:\n - " . implode("\n - ", $groupList) |
|
71 | - . "\n\nFor example:\nchmod g+w $filename\nchgrp " . $groupList[0] . " $filename"; |
|
70 | + . "one of these groups:\n - ".implode("\n - ", $groupList) |
|
71 | + . "\n\nFor example:\nchmod g+w $filename\nchgrp ".$groupList[0]." $filename"; |
|
72 | 72 | } else { |
73 | 73 | $message .= " There is no user-group that contains both the web-server user and the owner " |
74 | 74 | . "of this file. Change the ownership of the file, create a new group, or temporarily " |
@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | if (!class_exists(Solr::class)) { |
28 | 28 | return [ |
29 | 29 | EnvironmentCheck::ERROR, |
30 | - 'Class `' . Solr::class . '` not found. Is the fulltextsearch module installed?' |
|
30 | + 'Class `'.Solr::class.'` not found. Is the fulltextsearch module installed?' |
|
31 | 31 | ]; |
32 | 32 | } |
33 | 33 | |
@@ -43,7 +43,7 @@ discard block |
||
43 | 43 | if (!empty($brokenCores)) { |
44 | 44 | return [ |
45 | 45 | EnvironmentCheck::ERROR, |
46 | - 'The following indexes are unavailable: ' . implode($brokenCores, ', ') |
|
46 | + 'The following indexes are unavailable: '.implode($brokenCores, ', ') |
|
47 | 47 | ]; |
48 | 48 | } |
49 | 49 |
@@ -123,7 +123,7 @@ discard block |
||
123 | 123 | $goodTypes = [ValidationResult::TYPE_GOOD, ValidationResult::TYPE_INFO]; |
124 | 124 | $good = array_filter( |
125 | 125 | $this->result->getMessages(), |
126 | - function ($val, $key) use ($goodTypes) { |
|
126 | + function($val, $key) use ($goodTypes) { |
|
127 | 127 | if (in_array($val['messageType'], $goodTypes)) { |
128 | 128 | return true; |
129 | 129 | } |
@@ -132,14 +132,14 @@ discard block |
||
132 | 132 | ARRAY_FILTER_USE_BOTH |
133 | 133 | ); |
134 | 134 | if (!empty($good)) { |
135 | - $ret .= "GOOD: " . implode('; ', array_column($good, 'message')) . " "; |
|
135 | + $ret .= "GOOD: ".implode('; ', array_column($good, 'message'))." "; |
|
136 | 136 | } |
137 | 137 | |
138 | 138 | // Filter bad messages |
139 | 139 | $badTypes = [ValidationResult::TYPE_ERROR, ValidationResult::TYPE_WARNING]; |
140 | 140 | $bad = array_filter( |
141 | 141 | $this->result->getMessages(), |
142 | - function ($val, $key) use ($badTypes) { |
|
142 | + function($val, $key) use ($badTypes) { |
|
143 | 143 | if (in_array($val['messageType'], $badTypes)) { |
144 | 144 | return true; |
145 | 145 | } |
@@ -148,7 +148,7 @@ discard block |
||
148 | 148 | ARRAY_FILTER_USE_BOTH |
149 | 149 | ); |
150 | 150 | if (!empty($bad)) { |
151 | - $ret .= "BAD: " . implode('; ', array_column($bad, 'message')); |
|
151 | + $ret .= "BAD: ".implode('; ', array_column($bad, 'message')); |
|
152 | 152 | } |
153 | 153 | return $ret; |
154 | 154 | } |
@@ -56,7 +56,7 @@ |
||
56 | 56 | if ($cookie) { |
57 | 57 | return [ |
58 | 58 | EnvironmentCheck::ERROR, |
59 | - "Sessions are being set for {$fullURL} : Set-Cookie => " . $cookie, |
|
59 | + "Sessions are being set for {$fullURL} : Set-Cookie => ".$cookie, |
|
60 | 60 | ]; |
61 | 61 | } |
62 | 62 | return [ |