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

2.x: Logger pretty newlines #367

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

RiskoZoSlovenska
Copy link
Contributor

2.x backport of #320.

Additionally, unlike #320, this shouldn't introduce breaking changes to the return value of Logger:log().

@SinisterRectus
Copy link
Owner

I will review and possibly include this after 2.11.0.

msg = format(msg, ...)

local d = date(self._dateTime)
local prettyfied = msg
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to declare a new var here. Just re-use msg.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wanted to preserve the original value of msg because it's the value that the method returns, and so it shouldn't include extra formatting.

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.

2 participants