MCPcopy Create free account
hub / github.com/devnullvoid/pvetui / SetDebugEnabled

Function SetDebugEnabled

internal/logger/logger.go:296–305  ·  view source on GitHub ↗

SetDebugEnabled sets the global debug flag for the logger package. This should be called during application initialization to enable debug logging.

(enabled bool)

Source from the content-addressed store, hash-verified

294// SetDebugEnabled sets the global debug flag for the logger package.
295// This should be called during application initialization to enable debug logging.
296func SetDebugEnabled(enabled bool) {
297 // Elevate global logger level if already initialized.
298 if lg, ok := globalLogger.(*Logger); ok {
299 if enabled {
300 lg.SetLevel(LevelDebug)
301 } else {
302 lg.SetLevel(LevelInfo)
303 }
304 }
305}
306
307// GetPackageLogger returns a logger for a specific package using the global cache directory
308// This ensures all packages log to the same unified log file.

Callers 2

BootstrapFunction · 0.92

Calls 1

SetLevelMethod · 0.80

Tested by

no test coverage detected