Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Fix "async" config setup #181

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

scruti
Copy link
Contributor

@scruti scruti commented Dec 4, 2024

DfE::Analytics initialisation code ignored the config.async = false option when provided.

This was caused by the conditional assignment operator ||=, as foo ||= true does set foo = true if it was either nil or false.

Changed it to default to true only if no explicit value was set.

DfE::Analytics initialisation code was ignoring the
"config.async = false" option when provided, and setting it to
"config.async = true" anyways.

This was caused by the conditional assignment operator "||=".

"foo ||= true" does set 'foo' as 'true' if it was either 'nil' or
'false'.
@scruti
Copy link
Contributor Author

scruti commented Dec 4, 2024

Tests pass locally (at least on my setup!)
image

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant