code: func (c *Conn) MiddlewareFunc(middleware ...func(ctx *ReqCtx) error) {
  	c.middleware = append(c.middleware, middleware...)
  }
docs: // MiddlewareFunc registers middleware function to handle incoming request messages.