yod
This commit is contained in:
parent
bb19911526
commit
4e624e7bb5
12
main.go
12
main.go
@ -74,6 +74,18 @@ func wsHandler(w http.ResponseWriter, r *http.Request) {
|
||||
} else if buffer == "noise" {
|
||||
conn.WriteJSON(map[string]string{"action": "redirect", "url": "https://noiseprotocol.org/"})
|
||||
buffer = ""
|
||||
} else if buffer == "openbsd" {
|
||||
conn.WriteJSON(map[string]string{"action": "redirect", "url": "https://openbsd.org/"})
|
||||
buffer = ""
|
||||
} else if buffer == "linux" {
|
||||
conn.WriteJSON(map[string]string{"action": "show_message", "message": "Linux sucks"})
|
||||
buffer = ""
|
||||
} else if buffer == "mac" {
|
||||
conn.WriteJSON(map[string]string{"action": "show_message", "message": "Yet another BSD-like OS"})
|
||||
buffer = ""
|
||||
} else if buffer == "windows" {
|
||||
conn.WriteJSON(map[string]string{"action": "show_message", "message": "Windows ALLWAYS sucks"})
|
||||
buffer = ""
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user