-
-
Notifications
You must be signed in to change notification settings - Fork 825
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
[REF] Move getCustomFieldTokens to the tokens class, annotate more deprecations #21660
Conversation
(Standard links)
|
Test fail due to 2 changes being recently merged - all tests failing CRM_Member_Form_Task_PDFLetterTest::testMembershipTokenReplacementInPDF |
test this please |
@eileenmcnaughton needs rebase |
@eileenmcnaughton checkstyle strikes again |
@colemanw hopefully this time! |
@eileenmcnaughton just a few failures...
|
61d25b2
to
c7587de
Compare
@colemanw ok should be easy now since only the trait class calls that function now |
This deprecates (quietly) another function on CRM_Utils_Token. It's a pretty small function - the sort you'd just copy & paste if you wanted to use outside of core but I didn't add noise. The only core place that calls this is the tokenTrait - which is 'used' by activity tokens - but only for the handling of _N_ which I think was actually not supposed to have been included in the merge. Anyway - I'm leaving that question for later because I'm not sure if the token trait is used outside of core or how our final interface will look
@colemanw this time maybe.... (rebased again) |
Overview
Move getCustomFieldTokens to the tokens class, annotate more deprecations
This deprecates (quietly) another function on CRM_Utils_Token. It's a pretty small function -
the sort you'd just copy & paste if you wanted to use outside of core but
I didn't add noise.
Before
CRM_Utils_Token
being called for a 3 line function, only used in token classes, to get custom tokensAfter
Duplicated onto the class, deprecated (still called from the
TokenTrait
but from a function that is itself a candidate for removal - once we've checked universe. The only class that uses the trait has good test cover)Technical Details
The only core place that still calls this is the tokenTrait
whether that class actually needs the
_N_
handling that it uses the tokenTraitto possibly support (my recollection is that functionality is not enabled)
Anyway - I'm leaving that question for later because I'm not sure if the token
trait is used outside of core or how our final interface will look
Comments