2
2
3
3
namespace Vendic \PostnlApi \Service \DeliveryOptions ;
4
4
5
+ use Magento \Checkout \Model \Session ;
6
+ use Magento \Framework \Exception \LocalizedException ;
5
7
use Magento \Framework \Serialize \SerializerInterface ;
6
8
use TIG \PostNL \Helper \AddressEnhancer ;
7
9
use TIG \PostNL \Service \Carrier \Price \Calculator ;
8
10
use TIG \PostNL \Webservices \Endpoints \Locations as LocationsEndpoint ;
9
- use Magento \Checkout \Model \Session ;
10
- use Magento \Framework \Exception \LocalizedException ;
11
11
use Vendic \PostnlApi \Api \Data \LocationInterface ;
12
12
use Vendic \PostnlApi \Api \Data \LocationInterfaceFactory ;
13
13
use Vendic \PostnlApi \Api \Data \PostnlRequestInterface ;
@@ -78,7 +78,7 @@ private function getLocations($address)
78
78
$ quote = $ this ->checkoutSession ->getQuote ();
79
79
$ storeId = $ quote ->getStoreId ();
80
80
$ this ->locationsEndpoint ->changeAPIKeyByStoreId ($ storeId );
81
- $ this ->locationsEndpoint ->updateParameters ($ address , $ deliveryDate );
81
+ $ this ->locationsEndpoint ->updateParameters ($ address, $ deliveryDate );
82
82
$ response = $ this ->locationsEndpoint ->call ();
83
83
//@codingStandardsIgnoreLine
84
84
if (!is_object ($ response ) || !isset ($ response ->GetLocationsResult ->ResponseLocation )) {
@@ -93,7 +93,7 @@ private function getLocations($address)
93
93
$ factory = $ this ->locationFactory ;
94
94
95
95
return array_map (
96
- static function (array $ locationData ) use ($ factory ) {
96
+ static function (array $ locationData ) use ($ factory ) {
97
97
return $ factory ->create (['data ' => $ locationData ]);
98
98
},
99
99
$ responseArray
0 commit comments