diff --git a/internal/lnbits/webhook.go b/internal/lnbits/webhook.go index 643e415d..32741615 100644 --- a/internal/lnbits/webhook.go +++ b/internal/lnbits/webhook.go @@ -32,7 +32,7 @@ func NewWebhook(webhookServer string, bot *tb.Bot, client *Client, database *gor if !strings.Contains(webhookServer, "://") { log.Fatal("invalid webhook server configuration. please add a scheme.") } - _, port, err := net.SplitHostPort(strings.Split(webhookServer, "//")[1]) + host, port, err := net.SplitHostPort(strings.Split(webhookServer, "//")[1]) if err != nil { return nil } @@ -50,6 +50,7 @@ func NewWebhook(webhookServer string, bot *tb.Bot, client *Client, database *gor } apiServer.httpServer.Handler = apiServer.newRouter() go apiServer.httpServer.ListenAndServe() + log.Infof("[Webhook] Server started at %s port %s", host, port) return apiServer } diff --git a/internal/lnurl/server.go b/internal/lnurl/server.go index d6bf570d..0499b5a1 100644 --- a/internal/lnurl/server.go +++ b/internal/lnurl/server.go @@ -57,6 +57,7 @@ func NewServer(lnurlserver string, webhookserver string, bot *tb.Bot, client *ln apiServer.httpServer.Handler = apiServer.newRouter() go apiServer.httpServer.ListenAndServe() + log.Infof("[LNURL] Server started at %s port %s", host, port) return apiServer }