-
Type: Bug
-
Resolution: Fixed
-
Priority: Unknown
-
Affects Version/s: None
-
Component/s: None
-
None
-
Fully Compatible
-
Not Needed
-
There is a logging design oversight in which enabling logging with "options.LogComponentAll" does not result in the publication of logs. This issue arises because the "LevelComponentEnabled" method on the internal logger object fails to account for this specific use case. To resolve this, it is recommended to extend the method as follows:
func (logger *Logger) LevelComponentEnabled(level Level, component Component) bool {
return logger.ComponentLevels[component] >= level ||
logger.ComponentLevels[ComponentAll] >= level
}