Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bundle of fixes/updates for WorldPay JSON Gateway #26

Merged
merged 1 commit into from
Oct 23, 2017
Merged

Bundle of fixes/updates for WorldPay JSON Gateway #26

merged 1 commit into from
Oct 23, 2017

Conversation

leith
Copy link
Contributor

@leith leith commented Jul 18, 2017

This PR comes from writing an integration after @lukeholder's #22 was merged. I'm not entirely sure how @ugin is able to use this commercially because at the moment, the library will treat declined cards as successful payments.

This is what I've done:

  • Fix incorrect response class being generated (causes card declines to be accepted)
  • Fix purchase response message to actually have failure reason if available (instead of an error from no 'message')
  • Add more docblocks
  • Add proper abstract function definition for getEndpoint
  • Abstract JsonAuthorizeResponse to reduce duplication
  • Update unit test coverage, including distinction between failure, error and malformed cases

It's also worth noting that the JsonCaptureRequest class still has no unit tests - I'm not using it in my current integration yet, so I'm unlikely to add more coverage for this any time soon. Hopefully someone using it will be able to look into that in more detail.

@lukeholder
Copy link
Contributor

Thanks @leith - looks good.

* Fix incorrect response class being generated (causes card declines to be accepted)
* Fix purchase response message to actually have failure reason if available (instead of an error from no 'message')
* Add more docblocks
* Add proper abstract function definition for getEndpoint
* Abstract JsonAuthorizeResponse to reduce duplication
* Update unit test coverage, including distinction between failure, error and malformed cases
* Add JSON gateway to README
@kynx
Copy link

kynx commented Sep 7, 2017

@delatbabel Any news on this one? I'm looking at integrating WorldPay but the issue @leith uncovered is alarming.

@lukeholder
Copy link
Contributor

@delatbabel maybe this can be merged?

@kynx
Copy link

kynx commented Oct 2, 2017

@delatbabel @lukeholder If it's any help, I've confirmed the problem @leith describes exists against a WorldPay account and that this PR fixes the problem. Would be great to get this merged.

@barryvdh barryvdh merged commit 522fbac into thephpleague:master Oct 23, 2017
@barryvdh
Copy link
Member

Merged and tagged v2.2.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants