My suggestion is to revert the ParseLevel function to what it was before and instead introduce a ParseLevelEqualFold or ParseLevelCaseInsensitive or similar to the code base
I'd suggest to lower case all the switch cases as well. Which will allow users to have the intended behaviour by one single function.
The following commit introduced a bug for parsing log levels.
Please see my comment: https://github.com/rs/zerolog/commit/3543e9d94bc5ed088dd2d9ad1d19c7ccd0fa65f5#commitcomment-100418502
Proposed Solution
My suggestion is to revert theParseLevel
function to what it was before and instead introduce aParseLevelEqualFold
orParseLevelCaseInsensitive
or similar to the code baseI'd suggest to lower case all the switch cases as well. Which will allow users to have the intended behaviour by one single function.