actindi / act-fluent-logger-rails

Fluent logger
MIT License
118 stars 72 forks source link

Use message.inspect if message does not have encoding #22

Closed deanputney closed 8 years ago

deanputney commented 8 years ago

For debug level logging a developer may log an object or class without having converted it to a string beforehand. This PR checks that the logged message has an encoding and converts it to the inspected string if not so it can be properly logged.

quek commented 8 years ago

Thinks for your pull request.

I rewrite like this https://github.com/ruby/ruby/blob/trunk/lib/logger.rb#L516 and release v0.1.8.