refactor: clean up code

This commit is contained in:
Jonas Kaninda
2024-10-21 08:22:06 +02:00
parent dc20ea9635
commit f3ec395e37
5 changed files with 16 additions and 22 deletions

View File

@@ -41,15 +41,6 @@ func Error(msg string, args ...any) {
fmt.Printf("%s ERROR: %s\n", currentTime, formattedMessage)
}
}
func Done(msg string, args ...any) {
var currentTime = time.Now().Format("2006/01/02 15:04:05")
formattedMessage := fmt.Sprintf(msg, args...)
if len(args) == 0 {
fmt.Printf("%s INFO: %s\n", currentTime, msg)
} else {
fmt.Printf("%s INFO: %s\n", currentTime, formattedMessage)
}
}
// Fatal logs an error message and exits the program
func Fatal(msg string, args ...any) {