We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
@@ -34,7 +34,7 @@ |
||
| 34 | 34 | /** |
| 35 | 35 | * The main method of the eID script |
| 36 | 36 | * |
| 37 | - * @param ServerRequestInterface $request |
|
| 37 | + * @param ServerRequestInterface $request |
|
| 38 | 38 | * @return ResponseInterface XML response of search suggestions |
| 39 | 39 | */ |
| 40 | 40 | public function main(ServerRequestInterface $request) |
@@ -116,7 +116,7 @@ |
||
| 116 | 116 | } |
| 117 | 117 | foreach ($rows as $row) { |
| 118 | 118 | if ($row['format'] === 0 && $row['xpath']) { |
| 119 | - $uids[] = (int)$row['uid']; |
|
| 119 | + $uids[] = (int) $row['uid']; |
|
| 120 | 120 | } |
| 121 | 121 | } |
| 122 | 122 | return $uids; |
@@ -233,7 +233,7 @@ |
||
| 233 | 233 | if (!$cache) { |
| 234 | 234 | $conf['no_cache'] = true; |
| 235 | 235 | } |
| 236 | - $conf['parameter'] = $altPageId ?: ($this->pi_tmpPageId ?: 'current'); |
|
| 236 | + $conf['parameter'] = $altPageId ? : ($this->pi_tmpPageId ? : 'current'); |
|
| 237 | 237 | $conf['additionalParams'] = $this->conf['parent.']['addParams'] . HttpUtility::buildQueryString($urlParameters, '&', true) . $this->pi_moreParams; |
| 238 | 238 | // Add additional configuration for absolute URLs. |
| 239 | 239 | $conf['forceAbsoluteUrl'] = !empty($this->conf['forceAbsoluteUrl']) ? 1 : 0; |
@@ -87,7 +87,7 @@ discard block |
||
| 87 | 87 | ->delete('tx_dlf_tokens') |
| 88 | 88 | ->where( |
| 89 | 89 | $queryBuilder->expr()->eq('tx_dlf_tokens.ident', $queryBuilder->createNamedParameter('oai')), |
| 90 | - $queryBuilder->expr()->lt('tx_dlf_tokens.tstamp', $queryBuilder->createNamedParameter((int)($GLOBALS['EXEC_TIME'] - $this->conf['expired']))) |
|
| 90 | + $queryBuilder->expr()->lt('tx_dlf_tokens.tstamp', $queryBuilder->createNamedParameter((int) ($GLOBALS['EXEC_TIME'] - $this->conf['expired']))) |
|
| 91 | 91 | ) |
| 92 | 92 | ->execute(); |
| 93 | 93 | |
@@ -953,7 +953,7 @@ discard block |
||
| 953 | 953 | */ |
| 954 | 954 | protected function generateOutputForDocumentList(DocumentList $documentListSet) |
| 955 | 955 | { |
| 956 | - $documentsToProcess = $documentListSet->removeRange(0, (int)$this->conf['limit']); |
|
| 956 | + $documentsToProcess = $documentListSet->removeRange(0, (int) $this->conf['limit']); |
|
| 957 | 957 | $verb = $this->piVars['verb']; |
| 958 | 958 | |
| 959 | 959 | $connection = GeneralUtility::makeInstance(ConnectionPool::class) |
@@ -70,7 +70,7 @@ |
||
| 70 | 70 | if ($fetchedData) { |
| 71 | 71 | $response->getBody()->write($fetchedData); |
| 72 | 72 | $response = $response->withHeader('Access-Control-Allow-Methods', 'GET'); |
| 73 | - $response = $response->withHeader('Access-Control-Allow-Origin', $request->getHeaderLine('Origin') ?: '*'); |
|
| 73 | + $response = $response->withHeader('Access-Control-Allow-Origin', $request->getHeaderLine('Origin') ? : '*'); |
|
| 74 | 74 | $response = $response->withHeader('Access-Control-Max-Age', '86400'); |
| 75 | 75 | $response = $response->withHeader('Content-Type', finfo_buffer(finfo_open(FILEINFO_MIME), $fetchedData)); |
| 76 | 76 | } |
@@ -45,10 +45,10 @@ |
||
| 45 | 45 | { |
| 46 | 46 | return new ExpressionFunction( |
| 47 | 47 | 'getDocumentType', |
| 48 | - function () { |
|
| 48 | + function() { |
|
| 49 | 49 | // Not implemented, we only use the evaluator |
| 50 | 50 | }, |
| 51 | - function ($arguments, $cPid) { |
|
| 51 | + function($arguments, $cPid) { |
|
| 52 | 52 | /** @var RequestWrapper $requestWrapper */ |
| 53 | 53 | $requestWrapper = $arguments['request']; |
| 54 | 54 | $queryParams = $requestWrapper->getQueryParams(); |
@@ -58,10 +58,12 @@ |
||
| 58 | 58 | { |
| 59 | 59 | return new ExpressionFunction( |
| 60 | 60 | 'getDocumentType', |
| 61 | - function () { |
|
| 61 | + function () |
|
| 62 | + { |
|
| 62 | 63 | // Not implemented, we only use the evaluator |
| 63 | 64 | }, |
| 64 | - function ($arguments, $cPid) { |
|
| 65 | + function ($arguments, $cPid) |
|
| 66 | + { |
|
| 65 | 67 | /** @var RequestWrapper $requestWrapper */ |
| 66 | 68 | $requestWrapper = $arguments['request']; |
| 67 | 69 | $queryParams = $requestWrapper->getQueryParams(); |
@@ -335,7 +335,7 @@ |
||
| 335 | 335 | $config['path'] .= 'solr/'; |
| 336 | 336 | } |
| 337 | 337 | // Set connection timeout lower than PHP's max_execution_time. |
| 338 | - $max_execution_time = intval(ini_get('max_execution_time')) ?: 30; |
|
| 338 | + $max_execution_time = intval(ini_get('max_execution_time')) ? : 30; |
|
| 339 | 339 | $config['timeout'] = MathUtility::forceIntegerInRange($conf['solrTimeout'], 1, $max_execution_time, 10); |
| 340 | 340 | $this->config = $config; |
| 341 | 341 | } |
@@ -247,7 +247,8 @@ |
||
| 247 | 247 | * |
| 248 | 248 | * @return array fields |
| 249 | 249 | */ |
| 250 | - public static function getFields() { |
|
| 250 | + public static function getFields() |
|
| 251 | + { |
|
| 251 | 252 | $conf = unserialize($GLOBALS['TYPO3_CONF_VARS']['EXT']['extConf'][self::$extKey]); |
| 252 | 253 | |
| 253 | 254 | $fields = []; |
@@ -235,7 +235,7 @@ |
||
| 235 | 235 | $fields = Solr::getFields(); |
| 236 | 236 | $params = []; |
| 237 | 237 | // Restrict the fields to the required ones |
| 238 | - $params['fields'] = $fields['uid'] . ',' . $fields['id'] .',' . $fields['toplevel'] . ',' . $fields['thumbnail'] . ',' . $fields['page']; |
|
| 238 | + $params['fields'] = $fields['uid'] . ',' . $fields['id'] . ',' . $fields['toplevel'] . ',' . $fields['thumbnail'] . ',' . $fields['page']; |
|
| 239 | 239 | foreach ($this->solrConfig as $solr_name) { |
| 240 | 240 | $params['fields'] .= ',' . $solr_name; |
| 241 | 241 | } |
@@ -20,7 +20,8 @@ discard block |
||
| 20 | 20 | * @subpackage dlf |
| 21 | 21 | * @access public |
| 22 | 22 | */ |
| 23 | -class Region { |
|
| 23 | +class Region |
|
| 24 | +{ |
|
| 24 | 25 | |
| 25 | 26 | /** |
| 26 | 27 | * The identifier of the region |
@@ -104,7 +105,8 @@ discard block |
||
| 104 | 105 | * |
| 105 | 106 | * @return void |
| 106 | 107 | */ |
| 107 | - public function __construct($id, $region) { |
|
| 108 | + public function __construct($id, $region) |
|
| 109 | + { |
|
| 108 | 110 | $this->id = $id; |
| 109 | 111 | $this->pageId = $region['pageIdx']; |
| 110 | 112 | $this->xBeginPosition = $region['ulx']; |
@@ -123,7 +125,8 @@ discard block |
||
| 123 | 125 | * |
| 124 | 126 | * @return int The region's identifier |
| 125 | 127 | */ |
| 126 | - public function getId() { |
|
| 128 | + public function getId() |
|
| 129 | + { |
|
| 127 | 130 | return $this->id; |
| 128 | 131 | } |
| 129 | 132 | |
@@ -134,7 +137,8 @@ discard block |
||
| 134 | 137 | * |
| 135 | 138 | * @return int The region's page identifier |
| 136 | 139 | */ |
| 137 | - public function getPageId() { |
|
| 140 | + public function getPageId() |
|
| 141 | + { |
|
| 138 | 142 | return $this->pageId; |
| 139 | 143 | } |
| 140 | 144 | |
@@ -145,7 +149,8 @@ discard block |
||
| 145 | 149 | * |
| 146 | 150 | * @return int The region's horizontal beginning position |
| 147 | 151 | */ |
| 148 | - public function getXBeginPosition() { |
|
| 152 | + public function getXBeginPosition() |
|
| 153 | + { |
|
| 149 | 154 | return $this->xBeginPosition; |
| 150 | 155 | } |
| 151 | 156 | |
@@ -156,7 +161,8 @@ discard block |
||
| 156 | 161 | * |
| 157 | 162 | * @return int The region's horizontal ending position |
| 158 | 163 | */ |
| 159 | - public function getXEndPosition() { |
|
| 164 | + public function getXEndPosition() |
|
| 165 | + { |
|
| 160 | 166 | return $this->xEndPosition; |
| 161 | 167 | } |
| 162 | 168 | |
@@ -167,7 +173,8 @@ discard block |
||
| 167 | 173 | * |
| 168 | 174 | * @return int The region's vertical beginning position |
| 169 | 175 | */ |
| 170 | - public function getYBeginPosition() { |
|
| 176 | + public function getYBeginPosition() |
|
| 177 | + { |
|
| 171 | 178 | return $this->yBeginPosition; |
| 172 | 179 | } |
| 173 | 180 | |
@@ -178,7 +185,8 @@ discard block |
||
| 178 | 185 | * |
| 179 | 186 | * @return int The region's vertical ending position |
| 180 | 187 | */ |
| 181 | - public function getYEndPosition() { |
|
| 188 | + public function getYEndPosition() |
|
| 189 | + { |
|
| 182 | 190 | return $this->yEndPosition; |
| 183 | 191 | } |
| 184 | 192 | |
@@ -189,7 +197,8 @@ discard block |
||
| 189 | 197 | * |
| 190 | 198 | * @return int The region's width |
| 191 | 199 | */ |
| 192 | - public function getWidth() { |
|
| 200 | + public function getWidth() |
|
| 201 | + { |
|
| 193 | 202 | return $this->width; |
| 194 | 203 | } |
| 195 | 204 | |
@@ -200,7 +209,8 @@ discard block |
||
| 200 | 209 | * |
| 201 | 210 | * @return int The region's height |
| 202 | 211 | */ |
| 203 | - public function getHeight() { |
|
| 212 | + public function getHeight() |
|
| 213 | + { |
|
| 204 | 214 | return $this->height; |
| 205 | 215 | } |
| 206 | 216 | |
@@ -211,7 +221,8 @@ discard block |
||
| 211 | 221 | * |
| 212 | 222 | * @return string The region's text |
| 213 | 223 | */ |
| 214 | - public function getText() { |
|
| 224 | + public function getText() |
|
| 225 | + { |
|
| 215 | 226 | return $this->text; |
| 216 | 227 | } |
| 217 | 228 | } |