Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
dev/financial#12 move soft credit item count to object property #12011
Move the soft credit row count from a hardcoded variable to a class property that can be modified via hook.
Soft credit row count was hardcoded and couldn't be modified except through an override file.
Row count is now a class property that can be modified with the preProcess hook.
Oh wow! Our code is full of terrifying things!
What worries me here is that it does expose another thing to the hooks - which you obviously intend to alter - which could change at any time. If you want this to be non-upgrade-breaky you should lock in your intended usage with a test
I'm going to merge this as basically harmless & slightly better coding practice. Even better would have been for it to be a protected property with a public getter & setter function & even better would have been a unit test to lock it in. Key thing is merging this is no guarantee it won't change in a later patch.