Handle channel names ending with a slash better

This commit is contained in:
Ken-Håvard Lieng 2017-06-13 04:25:59 +02:00
parent f03b30eff6
commit 0f5c3b57d2
8 changed files with 96 additions and 40 deletions

View file

@ -103,7 +103,7 @@ func serve(w http.ResponseWriter, r *http.Request) {
return
}
if r.URL.Path == "/ws" {
if strings.HasPrefix(r.URL.Path, "/ws") {
session := handleAuth(w, r)
if session == nil {
log.Println("[Auth] No session")