From a1b95202344145cdcacc05ef1f5b0850057e309b Mon Sep 17 00:00:00 2001 From: Gert-Jan van der Molen Date: Fri, 9 Feb 2018 08:53:37 +0100 Subject: [PATCH] add pincode optional for voucher balance checks fashioncheque requires a pincode to retrieve the balance. this is currently unsupported. --- src/Voucher.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Voucher.php b/src/Voucher.php index df047539..989744d8 100644 --- a/src/Voucher.php +++ b/src/Voucher.php @@ -35,6 +35,9 @@ public static function balance(array $options = array()) if(isset($options['cardNumber'])){ $api->setCardNumber($options['cardNumber']); } + if(isset($options['pincode'])){ + $api->setPincode($options['pincode']); + } $result = $api->doRequest(); return $result['balance'] / 100; @@ -88,4 +91,4 @@ public static function activate(array $options = array()){ return $result['request']['result'] == 1; } -} \ No newline at end of file +}