@@ -92,7 +92,7 @@ |
||
92 | 92 | } |
93 | 93 | |
94 | 94 | /** |
95 | - * @return mixed |
|
95 | + * @return integer |
|
96 | 96 | */ |
97 | 97 | public function getErrorCode() |
98 | 98 | { |
@@ -51,7 +51,7 @@ |
||
51 | 51 | * |
52 | 52 | * @param \Vipps\VippsInterface $app |
53 | 53 | * @param string $subscription_key |
54 | - * @param $merchant_serial_number |
|
54 | + * @param string $merchant_serial_number |
|
55 | 55 | */ |
56 | 56 | public function __construct(VippsInterface $app, $subscription_key, $merchant_serial_number) |
57 | 57 | { |
@@ -122,7 +122,7 @@ |
||
122 | 122 | } |
123 | 123 | |
124 | 124 | /** |
125 | - * @param $path |
|
125 | + * @param string $path |
|
126 | 126 | * |
127 | 127 | * @return \Psr\Http\Message\UriInterface |
128 | 128 | */ |
@@ -10,8 +10,6 @@ |
||
10 | 10 | |
11 | 11 | use Doctrine\Common\Annotations\AnnotationRegistry; |
12 | 12 | use JMS\Serializer\SerializerBuilder; |
13 | -use Psr\Http\Message\RequestInterface; |
|
14 | -use Vipps\Exceptions\ViPPSErrorException; |
|
15 | 13 | use Vipps\Exceptions\VippsException; |
16 | 14 | use Vipps\VippsInterface; |
17 | 15 |
@@ -42,11 +42,11 @@ |
||
42 | 42 | |
43 | 43 | // Autodiscover X-Source-Address from env. |
44 | 44 | $this->headers['X-Source-Address'] = getenv('HTTP_CLIENT_IP') |
45 | - ?:getenv('HTTP_X_FORWARDED_FOR') |
|
46 | - ?:getenv('HTTP_X_FORWARDED') |
|
47 | - ?:getenv('HTTP_FORWARDED_FOR') |
|
48 | - ?:getenv('HTTP_FORWARDED') |
|
49 | - ?:getenv('REMOTE_ADDR') |
|
50 | - ?:gethostname(); |
|
45 | + ?: getenv('HTTP_X_FORWARDED_FOR') |
|
46 | + ?: getenv('HTTP_X_FORWARDED') |
|
47 | + ?: getenv('HTTP_FORWARDED_FOR') |
|
48 | + ?: getenv('HTTP_FORWARDED') |
|
49 | + ?: getenv('REMOTE_ADDR') |
|
50 | + ?: gethostname(); |
|
51 | 51 | } |
52 | 52 | } |
@@ -23,7 +23,7 @@ |
||
23 | 23 | parent::__construct($vipps, $subscription_key); |
24 | 24 | $this->headers['Authorization'] = |
25 | 25 | $this->app->getClient()->getTokenType() |
26 | - .' '. |
|
26 | + .' ' . |
|
27 | 27 | $this->app->getClient()->getToken(); |
28 | 28 | } |
29 | 29 | } |