Remove http.ListenAndServe in wrong place

This commit is contained in:
Tulir Asokan 2020-07-27 13:02:55 +03:00
parent 0430446d6d
commit 1aca93f250

View file

@ -18,7 +18,6 @@ package main
import (
"fmt"
"net/http"
"os"
"os/signal"
"strings"
@ -38,8 +37,6 @@ import (
"maunium.net/go/mautrix-whatsapp/database"
"maunium.net/go/mautrix-whatsapp/database/upgrades"
"maunium.net/go/mautrix-whatsapp/types"
"github.com/prometheus/client_golang/prometheus/promhttp"
)
var (
@ -406,9 +403,6 @@ func (bridge *Bridge) Main() {
bridge.Start()
bridge.Log.Infoln("Bridge started!")
http.Handle("/metrics", promhttp.Handler())
http.ListenAndServe("127.0.0.1:9093", nil)
c := make(chan os.Signal)
signal.Notify(c, os.Interrupt, syscall.SIGTERM)
<-c