improve error handling and messaging

This commit is contained in:
dd dd 2024-09-01 21:30:09 +02:00
parent a8d3de5a93
commit bedd0c5ec6
2 changed files with 2 additions and 2 deletions

View File

@ -119,7 +119,7 @@ func NewExit(ctx context.Context, exitNodeConfig *config.ExitConfig) *Exit {
}
err = exit.announceExitNode(ctx)
if err != nil {
panic(err)
slog.Error("failed to announce exit node", "error", err)
}
return exit
}

View File

@ -14,7 +14,7 @@ import (
const ten = 10
var errNoPublicKey = errors.New("no public key found")
var errNoPublicKey = errors.New("no public configuration")
func (e *Exit) announceExitNode(ctx context.Context) error {
if !e.config.Public {