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

fix: allow to pass messages as arrays or hashes #9

Merged
merged 3 commits into from
Dec 18, 2023
Merged

Conversation

nobe4
Copy link
Contributor

@nobe4 nobe4 commented Dec 18, 2023

Ruby's logger doesn't specify a type for message, so we can assume it to be any type.
The pragmatic possibilities are: String (default), Array and Hash.

This PR adds support to redact from an array and from the values of a hash.

Unfortunately, this brings a nasty double loop during the redaction process.

It also improves the tests.

@nobe4 nobe4 marked this pull request as ready for review December 18, 2023 15:43
@GrantBirki GrantBirki merged commit 2b00dbb into main Dec 18, 2023
4 checks passed
@GrantBirki GrantBirki deleted the fix_message branch December 18, 2023 16:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants