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 docs and behavior of WithContext #499

Merged
merged 3 commits into from
Oct 22, 2022
Merged

Fix docs and behavior of WithContext #499

merged 3 commits into from
Oct 22, 2022

Conversation

tep
Copy link
Contributor

@tep tep commented Oct 21, 2022

This change updates WithContext to better match documented behavior and also updates the documentation to both clarify existing behavior as well as the behavior expected by existing tests.

Note: since WithContext no longer employs a pointer receiver, the value comparison against the Context's attached logger value must be done via reflect.DeepEqual.

Fixes: #498

@rs rs merged commit e3027a5 into rs:master Oct 22, 2022
@jpalawaga
Copy link

Thank you for this. Was bitten by the docs not quite matching the behaviour in 1.2.6.

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.

Invalid condition in WithContext method.
3 participants