[interchange] enforce integer weights when writing to ups_cache database

Peter Ajamian <[email protected]>
Newsgroups gmane.comp.web.interchange.cvs
Message-ID <[email protected]>
commit f69e9c2f132d886658676762fc42d59b395dc812
Author: Steve Graham <[email protected]>
Date:   Fri Sep 16 14:28:25 2011 -0500

    enforce integer weights when writing to ups_cache database
    
    Signed-off-by: Peter Ajamian <[email protected]>
    
    Author:    Steve Graham <[email protected]>

 lib/Vend/Ship/QueryUPS.pm |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/lib/Vend/Ship/QueryUPS.pm b/lib/Vend/Ship/QueryUPS.pm
index 4aafb0c..85e4cc8 100644
--- a/lib/Vend/Ship/QueryUPS.pm
+++ b/lib/Vend/Ship/QueryUPS.pm
@@ -29,6 +29,7 @@ use Vend::Util;
 use Vend::Interpolate;
 use Vend::Data;
 use Vend::Ship;
+use POSIX qw(ceil);
 
 my $Have_Business_UPS;
 eval {
@@ -113,6 +114,7 @@ sub calculate {
 				or last CACHE;
 			my $tname = $db->name();
 			$cache = 1;
+			$weight = ceil($weight);
 			%cline = (
 				weight => $weight,
 				origin => $origin,
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.