"non-declaration statement outside function body" error golang : <p>I keep getting an non-declaration statement outside function body error for my http func method. I'm not sure why it keeps coming up after I fixed some global variables.</p>

<pre><code>    package main

import (
  "net/http"
  "github.com/gorilla/websocket"
)

var audioMessage   []byte
var whatType       int
var recieverReady  bool

http.HandleFunc("/send", func(w http.ResponseWriter, r *http.Request) {
  conn, _ := websocket.Upgrade(r, w)

  go func(){
        for {

      messageType, revdata, err := conn.ReadMessage()

      if recieverReady {
        audioMessage &lt;- revdata
        whatType     &lt;- messageType
      }
    }
    }()
})
</code></pre>
