From 3bd0737fd50e1a10ead3b568883aacaa583d09f2 Mon Sep 17 00:00:00 2001 From: Sagar Pawar Date: Mon, 26 Jun 2023 19:15:31 +0530 Subject: [PATCH] Added info methods --- log.go | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/log.go b/log.go index a77477b..33c6f89 100644 --- a/log.go +++ b/log.go @@ -64,11 +64,6 @@ func (logger *Logger) Debugln(values ...interface{}) { logger.debugLogger.Println(values...) } -// Info prints an info message -func (logger *Logger) Info(values ...interface{}) { - logger.infoLogger.Println(values...) -} - // Warning prints a warning message func (logger *Logger) Warning(values ...interface{}) { logger.warningLogger.Println(values...) @@ -143,3 +138,18 @@ func (logger *Logger) Panicf(format string, values ...interface{}) { func (logger *Logger) Panicln(values ...interface{}) { logger.errorLogger.Panicln(values...) } + +// Info prints an info message +func (logger *Logger) Info(values ...interface{}) { + logger.infoLogger.Println(values...) +} + +// Infof prints a formatted info message +func (logger *Logger) Infof(format string, values ...interface{}) { + logger.infoLogger.Printf(format, values...) +} + +// Infoln prints an info message with a newline character +func (logger *Logger) Infoln(values ...interface{}) { + logger.infoLogger.Println(values...) +}