Skip to content

Commit

Permalink
fix based on #2 solution
Browse files Browse the repository at this point in the history
  • Loading branch information
febriliankr committed Mar 13, 2023
1 parent 6769672 commit ef03226
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ func (wa *Whatsapp) UploadMedia(filepath string) (id string, err error) {
}
fmt.Printf("%s\n", string(body))
var res map[string]string
err = json.NewDecoder(resp.Body).Decode(&res)
err = json.NewDecoder(bytes.NewReader(body)).Decode(&res)
if err != nil {
return id, err
}
Expand Down

0 comments on commit ef03226

Please sign in to comment.