Browse Source

Fixed compilation issues

LEGOlord208 6 years ago
parent
commit
fede59cfa0
2 changed files with 2 additions and 2 deletions
  1. 1 1
      restapi.go
  2. 1 1
      types.go

+ 1 - 1
restapi.go

@@ -1018,7 +1018,7 @@ func (s *Session) GuildPruneCount(guildID string, days uint32) (count uint32, er
 		Pruned uint32 `json:"pruned"`
 	}{}
 
-	uri := EndpointGuildPrune(guildID) + "?days=" + days
+	uri := EndpointGuildPrune(guildID) + "?days=" + strconv.FormatUint(uint64(days), 10)
 	body, err := s.RequestWithBucketID("GET", uri, nil, EndpointGuildPrune(guildID))
 
 	err = unmarshal(body, &p)

+ 1 - 1
types.go

@@ -53,5 +53,5 @@ func newRestError(req *http.Request, resp *http.Response, body []byte) *RESTErro
 }
 
 func (r RESTError) Error() string {
-	return "HTTP " + r.Response.Status + ", " + r.ResponseBody
+	return "HTTP " + r.Response.Status + ", " + string(r.ResponseBody)
 }