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

OrderForm.php - process() misses an edge/rare case #41

Open
chrisrae opened this issue Apr 26, 2014 · 5 comments
Open

OrderForm.php - process() misses an edge/rare case #41

chrisrae opened this issue Apr 26, 2014 · 5 comments

Comments

@chrisrae
Copy link

Line 273

This will cause an uncaught ValidationException as it does not check the Member table, only the members linked to via the Customer table.

If I create an account (say the primary admin account when I install SS) with an email [email protected] and then I try to purchase an item using the [email protected] email address on the checkout page without being logged in - the system will try to write that member and blow up as a result. [email protected] won't be a customer, but will be a member, which SS will find out about when it tries to write a new member on top of it.

@frankmullenger
Copy link
Contributor

@chrisrae agree that this is an issue, would perhaps be resolved with changes to use member extension instead. Discussion here: https://github.com/frankmullenger/silverstripe-swipestripe/issues/42

@Zauberfisch
Copy link
Contributor

yes, the whole problem is the Customer class, and as far as I can see, we all agree to re factor out the Customer class in the next release.
For the time being, I don't really see a fix for this issue. At least not one that we could implement quickly.

I would rather invest the resources we have into a new release, than hunting down bugs that will be obsolete by the next version. My vote goes to close as wont-fix unless someone is willing to do a pull request.

@frankmullenger
Copy link
Contributor

Agree with @Zauberfisch, this should be fixed in the next version with the removal of Customer class so we could close this for now. @chrisrae are you happy with that approach?

@chrisrae
Copy link
Author

Totally fine.

Chris Rae - Web Services Manager
Darkside Media & Fluid Visual Communications
10 Memorial Street, Queenstown
Mob: 021 022 18625
Email: [email protected]
Tel: 3 442 6739

On Tue, May 13, 2014 at 8:41 PM, Frank Mullenger
[email protected]:

Agree with @Zauberfisch https://github.com/Zauberfisch, this should be
fixed in the next version with the removal of Customer class so we could
close this for now. @chrisrae https://github.com/chrisrae are you happy
with that approach?


Reply to this email directly or view it on GitHubhttps://github.com/frankmullenger/silverstripe-swipestripe/issues/41#issuecomment-42930638
.

@MilesSummers
Copy link

Suggest temporary fix change line 276 of OrderForm.php to
$existingCustomer = Member::get()->filter('Email', $data['Email']);

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

No branches or pull requests

4 participants