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

Ensure the httplog.Options from httplog.Logger are present in middleware.LogEntry #39

Closed

Conversation

stefansaasen
Copy link
Contributor

@stefansaasen stefansaasen commented Feb 15, 2024

This fixes #35 as the httplog.Options#JSON now causes the log entry to not be pretty printed to stderr if set to true.

…are.LogEntry

This fixes go-chi#35 as the httplog.Options#JSON now causes the log entry to
not be pretty printed to stderr if set to true.
@stefansaasen
Copy link
Contributor Author

This works but the test requires the changes from #38

@stefansaasen
Copy link
Contributor Author

This is similar to #34 but changing only the cause of the bug and adding a test for it. Credit really goes to @peter-teslenko for fixing #35

@stefansaasen stefansaasen changed the title Ensure the httplog.Options from httplog.Logger are present in middlew… Ensure the httplog.Options from httplog.Logger are present in middleware.LogEntry Feb 15, 2024
@stefansaasen
Copy link
Contributor Author

With #34 merged the bug has been fixed. This PR has a test for the change but not sure if that is worth adding. The httplog package doesn't have any tests to begin with.

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.

Make logger to print stack trace in file
1 participant