[REF] simplify interaction with objects in complete order
authoreileen <emcnaughton@wikimedia.org>
Sun, 6 Sep 2020 01:29:32 +0000 (13:29 +1200)
committereileen <emcnaughton@wikimedia.org>
Sun, 6 Sep 2020 01:31:21 +0000 (13:31 +1200)
commit62a721eda743ba248cf3b1a571a83f5fdbc72a56
treed1e61dc3db43b85c79345db480e1014b2b16a3d1
parentf412f88c64d28eba4010907227c6de3f49f87c16
[REF] simplify interaction with objects in complete order

Per https://github.com/civicrm/civicrm-core/pull/18382 this line seems to be heavily tested so
& per the test we can use the 'already calculated value' for payment_processor_id rather than look
it up in yet another place.

This adds a query but in most cases queries can be removed before calling this function as
the various objects are not really accessed anymore (apart from the few lines just above this)
CRM/Contribute/BAO/Contribution.php
tests/phpunit/CRM/Member/BAO/MembershipTest.php