summaryrefslogtreecommitdiff
path: root/internal/utils
diff options
context:
space:
mode:
Diffstat (limited to 'internal/utils')
-rw-r--r--internal/utils/log/log.go11
1 files changed, 11 insertions, 0 deletions
diff --git a/internal/utils/log/log.go b/internal/utils/log/log.go
index 0fff950..6cd16d5 100644
--- a/internal/utils/log/log.go
+++ b/internal/utils/log/log.go
@@ -21,3 +21,14 @@ func Warn(message string, a ...any) {
func Error(message string, a ...any) {
_ = logger.Error(message, a...)
}
+
+func SetLevel(level Level) (oldLevel Level) {
+ oldLevel = logger.Level
+ logger.Level = level
+ return
+}
+
+func GetLevel() Level {
+ return logger.Level
+}
+