Skip to content

Commit

Permalink
USPS: Remove trailing asterisks from rate names
Browse files Browse the repository at this point in the history
  • Loading branch information
Soleone committed Jan 10, 2011
1 parent cca7e73 commit 85a51e5
Show file tree
Hide file tree
Showing 4 changed files with 345 additions and 5 deletions.
4 changes: 2 additions & 2 deletions lib/active_shipping/shipping/carriers/usps.rb
Original file line number Diff line number Diff line change
Expand Up @@ -316,8 +316,8 @@ def rates_from_response_node(response_node, packages)
package_node.each_element(service_node) do |service_response_node|
service_name = service_response_node.get_text(service_name_node).to_s

# workaround for USPS messing up and including unescaped html in their rate names since Jan 2, 2011
service_name.gsub!(/<sup>®<\/sup>/, '')
# workaround for USPS messing up and including unescaped html and asterisks in their rate names since Jan 2, 2011
service_name.gsub!(/<sup>®<\/sup>|\*+$/, '')

# aggregate specific package rates into a service-centric RateEstimate
# first package with a given service name will initialize these;
Expand Down
Loading

0 comments on commit 85a51e5

Please sign in to comment.