aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--gsxlib.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/gsxlib.php b/gsxlib.php
index 4974754..3cc2702 100644
--- a/gsxlib.php
+++ b/gsxlib.php
@@ -238,7 +238,7 @@ class GsxLib
$req = array('ReturnLabel' => array(
'returnOrderNumber' => $returnOrder,
- 'partNumber' => $partNumber
+ 'partNumber' => $partNumber
));
return $this->request($req)->returnLabelData;
@@ -273,6 +273,8 @@ class GsxLib
public function warrantyStatus($serialNumber)
{
$serialNumber = trim($serialNumber);
+ // SNs should never start with an S, but they're often coded into barcodes
+ $serialNumber = ltrim($serialNumber, 'sS');
if (!self::looksLike($serialNumber, 'serialNumber')) {
exit('Invalid serial number: ' . $serialNumber);
@@ -349,5 +351,4 @@ class GsxLib
}
-
?> \ No newline at end of file