@@ -243,7 +243,7 @@ discard block |
||
| 243 | 243 | $this->logger->info("Loading data from ${file}"); |
| 244 | 244 | |
| 245 | 245 | if (!array_key_exists('target', $doc->getData())) { |
| 246 | - throw new MissingTargetException('Missing target in \'' . $file . '\''); |
|
| 246 | + throw new MissingTargetException('Missing target in \''.$file.'\''); |
|
| 247 | 247 | } |
| 248 | 248 | |
| 249 | 249 | $targetUrl = sprintf('%s%s', $host, $doc->getData()['target']); |
@@ -291,7 +291,7 @@ discard block |
||
| 291 | 291 | |
| 292 | 292 | // Authentication or custom headers. |
| 293 | 293 | if ($this->headerBasicAuth) { |
| 294 | - $data['headers']['Authorization'] = 'Basic '. base64_encode($this->headerBasicAuth); |
|
| 294 | + $data['headers']['Authorization'] = 'Basic '.base64_encode($this->headerBasicAuth); |
|
| 295 | 295 | } |
| 296 | 296 | if ($this->customHeaders) { |
| 297 | 297 | foreach ($this->customHeaders as $headers) { |
@@ -328,7 +328,7 @@ discard block |
||
| 328 | 328 | |
| 329 | 329 | if ($response->getStatusCode() <> 404) { |
| 330 | 330 | $response = $this->client->request('DELETE', $targetUrl, array_merge($data, ['http_errors' => false])); |
| 331 | - $this->logger->info("File deleted: ${targetUrl} (response code " . $response->getStatusCode().")"); |
|
| 331 | + $this->logger->info("File deleted: ${targetUrl} (response code ".$response->getStatusCode().")"); |
|
| 332 | 332 | } |
| 333 | 333 | } |
| 334 | 334 | |
@@ -338,7 +338,7 @@ discard block |
||
| 338 | 338 | $data |
| 339 | 339 | ); |
| 340 | 340 | |
| 341 | - $this->logger->info('Wrote ' . $response->getHeader('Link')[0]); |
|
| 341 | + $this->logger->info('Wrote '.$response->getHeader('Link')[0]); |
|
| 342 | 342 | } catch (\Exception $e) { |
| 343 | 343 | $this->errors[$file] = $e->getMessage(); |
| 344 | 344 | $this->logger->error( |
@@ -355,10 +355,10 @@ discard block |
||
| 355 | 355 | $this->cloner->cloneVar( |
| 356 | 356 | $this->parser->parse($e->getResponse()->getBody(), Yaml::PARSE_OBJECT_FOR_MAP) |
| 357 | 357 | ), |
| 358 | - function ($line, $depth) use ($output) { |
|
| 358 | + function($line, $depth) use ($output) { |
|
| 359 | 359 | if ($depth > 0) { |
| 360 | 360 | $output->writeln( |
| 361 | - '<error>' . str_pad(str_repeat(' ', $depth) . $line, 140, ' ') . '</error>' |
|
| 361 | + '<error>'.str_pad(str_repeat(' ', $depth).$line, 140, ' ').'</error>' |
|
| 362 | 362 | ); |
| 363 | 363 | } |
| 364 | 364 | } |
@@ -427,7 +427,7 @@ discard block |
||
| 427 | 427 | } |
| 428 | 428 | |
| 429 | 429 | // Find file |
| 430 | - $fileName = dirname($originFile) . DIRECTORY_SEPARATOR . $documentData['file']; |
|
| 430 | + $fileName = dirname($originFile).DIRECTORY_SEPARATOR.$documentData['file']; |
|
| 431 | 431 | $fileName = str_replace('//', '/', $fileName); |
| 432 | 432 | if (!file_exists($fileName)) { |
| 433 | 433 | return false; |