ayn2op 1 год назад
Родитель
Сommit
a098f47732
2 измененных файлов с 1 добавлено и 4 удалено
  1. 0 1
      go.mod
  2. 1 3
      internal/logger/logger.go

+ 0 - 1
go.mod

@@ -8,7 +8,6 @@ require (
 	github.com/diamondburned/arikawa/v3 v3.4.0
 	github.com/diamondburned/ningen/v3 v3.0.1-0.20240808103805-f1a24c0da3d8
 	github.com/gdamore/tcell/v2 v2.7.4
-	github.com/lmittmann/tint v1.0.5
 	github.com/rivo/tview v0.0.0-20241103174730-c76f7879f592
 	github.com/skratchdot/open-golang v0.0.0-20200116055534-eef842397966
 	github.com/yuin/goldmark v1.7.8

+ 1 - 3
internal/logger/logger.go

@@ -6,7 +6,6 @@ import (
 	"path/filepath"
 
 	"github.com/ayn2op/discordo/internal/config"
-	"github.com/lmittmann/tint"
 )
 
 // Recursively creates the log directory if it does not exist already and returns the path to the log file.
@@ -36,8 +35,7 @@ func Load() error {
 		return err
 	}
 
-	h := tint.NewHandler(file, nil)
-	l := slog.New(h)
+	l := slog.New(slog.NewTextHandler(file, &slog.HandlerOptions{AddSource: true}))
 	slog.SetDefault(l)
 	return nil
 }