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

Make it obvious that we are only passing payment_processor_id to loadRelatedObjects #18518

Closed

Conversation

mattwire
Copy link
Contributor

Overview

Partial from #18313. Pass only the required params to loadRelatedObjects for complete/repeattransaction

Before

Passing $input array.

After

Passing specific parameters

Technical Details

Comments

@eileenmcnaughton I tried moving loadRelatedObjects to _ipn_process_transaction but that causes problems because we mess with (unset some bits) the contribution object before passing and that breaks it. This is a simple cleanup that will probably help us remove the call entirely.

@civibot
Copy link

civibot bot commented Sep 18, 2020

(Standard links)

@civibot civibot bot added the master label Sep 18, 2020
@eileenmcnaughton
Copy link
Contributor

@mattwire why not just pass $input['payment_processor_id'] to completeOrder & skip loadRelatedObjects altogether? contribution & payment processor are the only objects passed in now & the 2 processors that call his could easily be adapted to pass in $input['payment_processor_id']. For the last place (#18479) we shouldn't pass it in at all

I think logically payment_processor_id is an input param - ie it's a piece of information we know at payment time about how the payment is happening

@mattwire
Copy link
Contributor Author

@eileenmcnaughton Makes sense - see #18528

@mattwire mattwire closed this Sep 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants