Add errors

This commit is contained in:
qowevisa 2024-05-01 17:32:27 +03:00
parent 9f8319126f
commit 716be466e0

View File

@ -1,6 +1,10 @@
package tui
import "git.qowevisa.me/Qowevisa/gotell/errors"
import (
"log"
"git.qowevisa.me/Qowevisa/gotell/errors"
)
func (t *TUI) launchErrorsChannel() error {
if t.errorsChannel == nil {
@ -9,6 +13,7 @@ func (t *TUI) launchErrorsChannel() error {
go func() {
for err := range t.errorsChannel {
if err != nil {
log.Printf("ERROR: %#v\n", err)
t.createNotification(err.Error(), CONST_ERROR_N_TITLE)
}
}