Skip to content

Commit

Permalink
Fixed ship-to address for UPS REST shipment API (#4047)
Browse files Browse the repository at this point in the history
Co-authored-by: Rob Agnese <[email protected]>
  • Loading branch information
ragnese and Rob Agnese authored Jul 2, 2024
1 parent 3da8c6e commit 5610151
Showing 1 changed file with 0 additions and 13 deletions.
13 changes: 0 additions & 13 deletions app/code/core/Mage/Usa/Model/Shipping/Carrier/Ups.php
Original file line number Diff line number Diff line change
Expand Up @@ -1859,19 +1859,6 @@ protected function _formShipmentRestRequest(Varien_Object $request): string
if ($request->getShipperAddressStateOrProvinceCode()) {
$address['StateProvinceCode'] = $request->getShipperAddressStateOrProvinceCode();
}

$shipToAddress = &$shipToData['Address'];
$shipToAddress['AddressLine'] =
$request->getShipperAddressStreet1() . ' ' . $request->getShipperAddressStreet2();
$shipToAddress['City'] = $request->getShipperAddressCity();
$shipToAddress['CountryCode'] = $request->getShipperAddressCountryCode();
$shipToAddress['PostalCode'] = $request->getShipperAddressPostalCode();
if ($request->getShipperAddressStateOrProvinceCode()) {
$shipToAddress['StateProvinceCode'] = $request->getShipperAddressStateOrProvinceCode();
}
if ($this->getConfigData('dest_type') == 'RES') {
$shipToAddress['ResidentialAddress'] = '';
}
}

$shipParams['ShipmentRequest']['Shipment']['Service']['Code'] = $request->getShippingMethod();
Expand Down

0 comments on commit 5610151

Please sign in to comment.