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

[REF] Extract code to load the contact in tokenCompat #21450

Merged
merged 1 commit into from
Sep 13, 2021

Conversation

eileenmcnaughton
Copy link
Contributor

Overview

Extraction of the code to load contact - this is an attempt to break an easy-merge chunk from #21449

Before

getContact is happening during evaluate

After

It is extracted

Technical Details

This isn't quite a pure extraction - it adds a bool for $getAll which allows us to load all when we want them for the token hook but not to otherwise. The other reason why we were loading all return properties is that last time around we got test fails when we didn't. I'm pretty sure that was because the greeting fields weren't being requested so I've added handling to grab those.

Note I also copied the array of return properties to a function since we want to work through them at some point to retrieve using apiv4

Comments

@civibot
Copy link

civibot bot commented Sep 13, 2021

(Standard links)

@colemanw
Copy link
Member

I agree with the extraction and so do the unit tests.

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