@@ -3,13 +3,13 @@ |
||
3 | 3 | use Guzzle\Http\Client; |
4 | 4 | use LinusShops\CanadaPost\Service; |
5 | 5 | /** |
6 | - * Get the nearest post office |
|
7 | - * |
|
8 | - * @see https://www.canadapost.ca/cpo/mc/business/productsservices/developers/services/findpostoffice/nearestpostoffice.jsf |
|
9 | - * @author Sam Schmidt <[email protected]> |
|
10 | - * @since 2015-12-09 |
|
11 | - * @company Linus Shops |
|
12 | - */ |
|
6 | + * Get the nearest post office |
|
7 | + * |
|
8 | + * @see https://www.canadapost.ca/cpo/mc/business/productsservices/developers/services/findpostoffice/nearestpostoffice.jsf |
|
9 | + * @author Sam Schmidt <[email protected]> |
|
10 | + * @since 2015-12-09 |
|
11 | + * @company Linus Shops |
|
12 | + */ |
|
13 | 13 | |
14 | 14 | class GetNearestPostOffice extends Service |
15 | 15 | { |
@@ -2,12 +2,12 @@ |
||
2 | 2 | namespace LinusShops\CanadaPost\Services; |
3 | 3 | use LinusShops\CanadaPost\Service; |
4 | 4 | /** |
5 | - * |
|
6 | - * |
|
7 | - * @author Sam Schmidt <[email protected]> |
|
8 | - * @since 2015-12-09 |
|
9 | - * @company Linus Shops |
|
10 | - */ |
|
5 | + * |
|
6 | + * |
|
7 | + * @author Sam Schmidt <[email protected]> |
|
8 | + * @since 2015-12-09 |
|
9 | + * @company Linus Shops |
|
10 | + */ |
|
11 | 11 | |
12 | 12 | class GetNearestPostOffice extends Service |
13 | 13 | { |
@@ -58,7 +58,7 @@ discard block |
||
58 | 58 | return $this; |
59 | 59 | } |
60 | 60 | |
61 | - public function getParameter($name, $default=null) |
|
61 | + public function getParameter($name, $default = null) |
|
62 | 62 | { |
63 | 63 | return $this->hasParameter($name) ? |
64 | 64 | $this->parameters[$name] : $default; |
@@ -82,8 +82,8 @@ discard block |
||
82 | 82 | $request = $this->buildRequest(); |
83 | 83 | |
84 | 84 | //Apply standard headers |
85 | - $this->setHeader('Authorization', 'Basic '.base64_encode( |
|
86 | - $this->userid.':'.$this->password |
|
85 | + $this->setHeader('Authorization', 'Basic ' . base64_encode( |
|
86 | + $this->userid . ':' . $this->password |
|
87 | 87 | )); |
88 | 88 | |
89 | 89 | $client = new Client(array( |
@@ -1,9 +1,9 @@ |
||
1 | 1 | <?php |
2 | 2 | require __DIR__ . '/../vendor/autoload.php'; |
3 | -$configfile = __DIR__.'/config.json'; |
|
3 | +$configfile = __DIR__ . '/config.json'; |
|
4 | 4 | $config = false; |
5 | 5 | if (file_exists($configfile)) { |
6 | - $config = json_decode(file_get_contents(__DIR__.'/config.json'), true); |
|
6 | + $config = json_decode(file_get_contents(__DIR__ . '/config.json'), true); |
|
7 | 7 | } |
8 | 8 | |
9 | 9 | if ($config == false) { |