TTDL-5 Added better error handling

This commit is contained in:
Pijus Kamandulis committed 2020-02-25 20:12:01 +02:00
1 parent 1b3f985f42
commit 7a691ad32d
10 files changed
+113 -41

No files matched your search

+6
View File
@@ -3,6 +3,7 @@ package utils
import (
config "../models/config"
"fmt"
"os"
)
// Log - Write to std out
@@ -23,3 +24,8 @@ func Logf(format string, a ...interface{}) {
func LogFatal(format string, a ...interface{}) {
panic(fmt.Sprintf(format, a...))
}
// LogErr - Write error
func LogErr(format string, a ...interface{}) {
fmt.Fprintf(os.Stderr, format, a...)
}