diff options
Diffstat (limited to 'web.go')
-rw-r--r-- | web.go | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -21,7 +21,7 @@ const SESSION_NAME = "easybridge_session" var sessionsStore sessions.Store = nil var userKeys = map[string]*[32]byte{} -func StartWeb() { +func StartWeb(errch chan error) { session_key := blake2b.Sum256([]byte(config.SessionKey)) sessionsStore = sessions.NewCookieStore(session_key[:]) @@ -39,7 +39,7 @@ func StartWeb() { go func() { err := http.ListenAndServe(config.WebBindAddr, logRequest(r)) if err != nil { - log.Fatal("Cannot start http server: ", err) + errch <- err } }() } |