(params martini.Params)
| 88 | } |
| 89 | |
| 90 | func (s *apiServer) verifyXAuth(params martini.Params) error { |
| 91 | if s.proxy.IsClosed() { |
| 92 | return ErrClosedProxy |
| 93 | } |
| 94 | xauth := params["xauth"] |
| 95 | if xauth == "" { |
| 96 | return errors.New("missing xauth, please check product name & auth") |
| 97 | } |
| 98 | if xauth != s.proxy.XAuth() { |
| 99 | return errors.New("invalid xauth, please check product name & auth") |
| 100 | } |
| 101 | return nil |
| 102 | } |
| 103 | |
| 104 | func (s *apiServer) Overview() (int, string) { |
| 105 | return rpc.ApiResponseJson(s.proxy.Overview(StatsFull)) |
no test coverage detected