3
0
mirror of https://github.com/ergochat/ergo.git synced 2024-11-14 16:09:32 +01:00

Merge pull request #1154 from slingamn/fields

delete some unused fields
This commit is contained in:
Shivaram Lingamneni 2020-06-24 14:22:43 -07:00 committed by GitHub
commit fb7a460ee9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -9,7 +9,6 @@ import (
"net/http" "net/http"
"os" "os"
"strings" "strings"
"sync"
"time" "time"
"github.com/gorilla/websocket" "github.com/gorilla/websocket"
@ -112,12 +111,10 @@ func (nl *NetListener) serve() {
// WSListener is a listener for IRC-over-websockets (initially HTTP, then upgraded to a // WSListener is a listener for IRC-over-websockets (initially HTTP, then upgraded to a
// different application protocol that provides a message-based API, possibly with TLS) // different application protocol that provides a message-based API, possibly with TLS)
type WSListener struct { type WSListener struct {
sync.Mutex // tier 1
listener *utils.ReloadableListener listener *utils.ReloadableListener
httpServer *http.Server httpServer *http.Server
server *Server server *Server
addr string addr string
config utils.ListenerConfig
} }
func NewWSListener(server *Server, addr string, listener *utils.ReloadableListener, config utils.ListenerConfig) (result *WSListener, err error) { func NewWSListener(server *Server, addr string, listener *utils.ReloadableListener, config utils.ListenerConfig) (result *WSListener, err error) {
@ -125,7 +122,6 @@ func NewWSListener(server *Server, addr string, listener *utils.ReloadableListen
listener: listener, listener: listener,
server: server, server: server,
addr: addr, addr: addr,
config: config,
} }
result.httpServer = &http.Server{ result.httpServer = &http.Server{
Handler: http.HandlerFunc(result.handle), Handler: http.HandlerFunc(result.handle),