Before data is sent to Guzzle, any null parameters are set to empty strings. This will ensure all POST parameters have an "=" appended. Whether SagePay has been fixed to accept parameter foo as equivalent to parameter foo= or not, this fix will do no harm.
This fix could do with an additional test, but I will need guidance on how that would work. Basically, given a BillingAddress2 set to null, the assertion is that the POST parameters sent to Guzzle should include the element "BillingAddress2" => "" and not "BillingAddress2" => null.
Before data is sent to Guzzle, any null parameters are set to empty strings. This will ensure all POST parameters have an "=" appended. Whether SagePay has been fixed to accept parameter
foo
as equivalent to parameterfoo=
or not, this fix will do no harm.This fix could do with an additional test, but I will need guidance on how that would work. Basically, given a BillingAddress2 set to null, the assertion is that the POST parameters sent to Guzzle should include the element
"BillingAddress2" => ""
and not"BillingAddress2" => null
.