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

Singletons / multiple requests bug #25

Closed
fsalomon opened this issue Mar 7, 2016 · 0 comments
Closed

Singletons / multiple requests bug #25

fsalomon opened this issue Mar 7, 2016 · 0 comments

Comments

@fsalomon
Copy link

fsalomon commented Mar 7, 2016

Why are you using singletons for stuff like CheckoutApi_Lib_RespondObj and CheckoutApi_Lib_ExceptionState? Seems like a poor design decision.

This is causing a critial bug: If one request fails and throws an exception, subsequent requests will throw exceptions, too. That's because CheckoutApi_Lib_ExceptionState is reused. To reproduce, make one verifyPaymentToken request with an invalid token and then try doing a createPaymentToken request. Both requests will throw an exception.

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

No branches or pull requests

2 participants