@@ -56,7 +56,7 @@ |
||
| 56 | 56 | /** |
| 57 | 57 | * @param string $method |
| 58 | 58 | * @param string $url |
| 59 | - * @param array $data |
|
| 59 | + * @param string $body |
|
| 60 | 60 | * |
| 61 | 61 | * @return array |
| 62 | 62 | * |
@@ -7,12 +7,8 @@ |
||
| 7 | 7 | use Http\Client\Exception\TransferException; |
| 8 | 8 | use Http\Client\HttpClient; |
| 9 | 9 | use Http\Client\Plugin\ErrorPlugin; |
| 10 | -use Http\Client\Plugin\LoggerPlugin; |
|
| 11 | 10 | use Http\Client\Plugin\PluginClient; |
| 12 | -use Http\Discovery\HttpClientDiscovery; |
|
| 13 | -use Http\Discovery\MessageFactoryDiscovery; |
|
| 14 | 11 | use Http\Message\MessageFactory; |
| 15 | -use Psr\Log\LoggerInterface; |
|
| 16 | 12 | |
| 17 | 13 | class RequestManager |
| 18 | 14 | { |
@@ -53,8 +53,8 @@ discard block |
||
| 53 | 53 | |
| 54 | 54 | /** |
| 55 | 55 | * @param $key |
| 56 | - * @param $method |
|
| 57 | - * @param $resource |
|
| 56 | + * @param string $method |
|
| 57 | + * @param string $resource |
|
| 58 | 58 | * @param null $body |
| 59 | 59 | * @param string $type |
| 60 | 60 | * @param array $extraQuery |
@@ -247,7 +247,7 @@ discard block |
||
| 247 | 247 | /** |
| 248 | 248 | * @param $project |
| 249 | 249 | * @param $messageId |
| 250 | - * @param $domain |
|
| 250 | + * @param string $domain |
|
| 251 | 251 | */ |
| 252 | 252 | protected function addTagToAsset($project, $messageId, $domain) |
| 253 | 253 | { |
@@ -294,7 +294,7 @@ discard block |
||
| 294 | 294 | /** |
| 295 | 295 | * @param array $config |
| 296 | 296 | * @param $domain |
| 297 | - * @param $useDomainAsFilter |
|
| 297 | + * @param boolean $useDomainAsFilter |
|
| 298 | 298 | */ |
| 299 | 299 | protected function doUploadDomains(array &$config, $domain, $useDomainAsFilter) |
| 300 | 300 | { |
@@ -345,7 +345,7 @@ discard block |
||
| 345 | 345 | /** |
| 346 | 346 | * @param array $config |
| 347 | 347 | * @param $domain |
| 348 | - * @param $useDomainAsFilter |
|
| 348 | + * @param boolean $useDomainAsFilter |
|
| 349 | 349 | */ |
| 350 | 350 | protected function doSynchronizeDomain(array &$config, $domain, $useDomainAsFilter) |
| 351 | 351 | { |
@@ -433,7 +433,6 @@ discard block |
||
| 433 | 433 | } |
| 434 | 434 | |
| 435 | 435 | /** |
| 436 | - * @param array $config |
|
| 437 | 436 | * |
| 438 | 437 | * @return array |
| 439 | 438 | */ |
@@ -2,7 +2,6 @@ |
||
| 2 | 2 | |
| 3 | 3 | namespace Happyr\TranslationBundle\Service; |
| 4 | 4 | |
| 5 | -use Happyr\TranslationBundle\Exception\HappyrTranslationException; |
|
| 6 | 5 | use Happyr\TranslationBundle\Exception\HttpException; |
| 7 | 6 | use Happyr\TranslationBundle\Http\RequestManager; |
| 8 | 7 | use Happyr\TranslationBundle\Model\Message; |
@@ -77,7 +77,7 @@ discard block |
||
| 77 | 77 | } |
| 78 | 78 | |
| 79 | 79 | $query = array_merge($extraQuery, ['key' => $key]); |
| 80 | - $url = self::BASE_URL . $resource . '?' . http_build_query($query); |
|
| 80 | + $url = self::BASE_URL.$resource.'?'.http_build_query($query); |
|
| 81 | 81 | |
| 82 | 82 | return $this->requestManager->send($method, $url, $body, $headers); |
| 83 | 83 | } |
@@ -196,10 +196,10 @@ discard block |
||
| 196 | 196 | $notes = ''; |
| 197 | 197 | foreach ($message->getParameters() as $key => $value) { |
| 198 | 198 | if (!is_array($value)) { |
| 199 | - $notes .= 'Parameter: ' . $key . ' (i.e. : ' . $value . ")\n"; |
|
| 199 | + $notes .= 'Parameter: '.$key.' (i.e. : '.$value.")\n"; |
|
| 200 | 200 | } else { |
| 201 | 201 | foreach ($value as $k => $v) { |
| 202 | - $notes .= 'Parameter: ' . $k . ' (i.e. : ' . $v . ")\n"; |
|
| 202 | + $notes .= 'Parameter: '.$k.' (i.e. : '.$v.")\n"; |
|
| 203 | 203 | } |
| 204 | 204 | } |
| 205 | 205 | } |
@@ -398,13 +398,13 @@ discard block |
||
| 398 | 398 | } |
| 399 | 399 | foreach ($subnode as $key => $value) { |
| 400 | 400 | if (is_array($value)) { |
| 401 | - $nodePath = $path ? $path . '.' . $key : $key; |
|
| 401 | + $nodePath = $path ? $path.'.'.$key : $key; |
|
| 402 | 402 | $this->flatten($messages, $value, $nodePath); |
| 403 | 403 | if (null === $path) { |
| 404 | 404 | unset($messages[$key]); |
| 405 | 405 | } |
| 406 | 406 | } elseif (null !== $path) { |
| 407 | - $messages[$path . '.' . $key] = $value; |
|
| 407 | + $messages[$path.'.'.$key] = $value; |
|
| 408 | 408 | } |
| 409 | 409 | } |
| 410 | 410 | } |