Skip to content

Commit

Permalink
Allow negative Offset values for GetUpdates, closes #51.
Browse files Browse the repository at this point in the history
  • Loading branch information
Syfaro committed Jun 29, 2016
1 parent 13f3185 commit 1daed40
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bot.go
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ func (bot *BotAPI) GetFile(config FileConfig) (File, error) {
// instantly instead of having to wait between requests.
func (bot *BotAPI) GetUpdates(config UpdateConfig) ([]Update, error) {
v := url.Values{}
if config.Offset > 0 {
if config.Offset != 0 {
v.Add("offset", strconv.Itoa(config.Offset))
}
if config.Limit > 0 {
Expand Down

0 comments on commit 1daed40

Please sign in to comment.