livereload: Simplify conditional

This commit is contained in:
srinivasreddy 2016-03-20 23:49:51 +05:30 committed by Bjørn Erik Pedersen
parent 2c5e4f7640
commit bafb77172b

View file

@ -33,8 +33,7 @@ func (c *connection) reader() {
if err != nil {
break
}
switch true {
case bytes.Contains(message, []byte(`"command":"hello"`)):
if bytes.Contains(message, []byte(`"command":"hello"`)){
c.send <- []byte(`{
"command": "hello",
"protocols": [ "http://livereload.com/protocols/official-7" ],