1
0

🚑 Fixed args indirect

This commit is contained in:
Maxim Lebedev 2017-10-17 17:43:01 +05:00
parent 706baf4a24
commit 8aff12b073
No known key found for this signature in database
GPG Key ID: F8978F46FF0FFA4F

View File

@ -15,7 +15,7 @@ const (
func (bot *Bot) request(dst []byte, method string, args *http.Args) (*Response, error) {
requestURI := fmt.Sprintf(APIEndpoint, bot.AccessToken, method)
if &args != nil {
if args != nil {
requestURI += fmt.Sprint("?", args.String())
}
@ -45,7 +45,7 @@ func (bot *Bot) request(dst []byte, method string, args *http.Args) (*Response,
func (bot *Bot) upload(dst []byte, boundary, method string, args *http.Args) (*Response, error) {
requestURI := fmt.Sprintf(APIEndpoint, bot.AccessToken, method)
if &args != nil {
if args != nil {
requestURI += fmt.Sprint("?", args.String())
}