onjara / optic

A powerful logging framework for Deno
MIT License
44 stars 4 forks source link

Log levels names are capitalized #5

Closed denizdogan closed 1 year ago

denizdogan commented 1 year ago

This one caught me off guard, and sometimes still does. Why is it e.g. Trace and not trace? Is it a bug or intentional?

OPTIC_MIN_LEVEL=trace  # doesn't work!
OPTIC_MIN_LEVEL=Trace  # works!

Could we normalize the level names to lowercase?

cknight commented 1 year ago

Thanks for the feedback. There was no special reason to enforce this, so I've added the ability for those inputs to be case insensitive. Fixed in 11303da69437a2ca5ad83cdfa1305c6499fe5c66. Now available in release 1.3.6.