Re: Beta1 Shipping Bug

Posts: 967
Joined: 11/05/2007
Bug FinderFAQ ModeratorGetting busy with the Ubercode.

After upgrading from Alpha 8, where all shipping rate quotes were working properly, I too found that I wasn't getting any USPS rate quotes.

I traced problem with USPS shipping quotes not returning any quotes to this piece of code (bazaar version 728 of uc_usps.module):

<?php
   
if ($service != 'data' || !in_array($service, $usps_services)){
      unset(
$services[$service]);
    }
?>

This condition will always evaluate to TRUE, since $service is never = 'data'. The result is that no rate quotes will be returned from the USPS module.

Changing the above lines to:

<?php
   
if (!in_array($service, $usps_services)){
      unset(
$services[$service]);
    }
?>

fixes the problem.

--

<tr>.

Beta1 Shipping Bug By: barliesque (42 replies) Sun, 01/13/2008 - 22:58