From 3c1efd07af3fc823636149cfabca835b0f871138 Mon Sep 17 00:00:00 2001 From: Del Date: Wed, 27 Jan 2016 10:55:17 +0800 Subject: [PATCH] fix validate so it does not throw an error on parameters with a zero value --- src/Omnipay/Common/Message/AbstractRequest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Omnipay/Common/Message/AbstractRequest.php b/src/Omnipay/Common/Message/AbstractRequest.php index e19e3085..299db883 100644 --- a/src/Omnipay/Common/Message/AbstractRequest.php +++ b/src/Omnipay/Common/Message/AbstractRequest.php @@ -209,7 +209,7 @@ public function validate() { foreach (func_get_args() as $key) { $value = $this->parameters->get($key); - if (empty($value)) { + if (! isset($value)) { throw new InvalidRequestException("The $key parameter is required"); } }