diff --git a/file.go b/file.go index dc7ffbb..14c40f9 100644 --- a/file.go +++ b/file.go @@ -9,7 +9,7 @@ import ( type File struct { FileID string `json:"file_id"` UniqueID string `json:"file_unique_id"` - FileSize int `json:"file_size"` + FileSize int64 `json:"file_size"` // FilePath is used for files on Telegram server. FilePath string `json:"file_path"` diff --git a/sendable.go b/sendable.go index a91233e..38d8b48 100644 --- a/sendable.go +++ b/sendable.go @@ -87,7 +87,7 @@ func (d *Document) Send(b *Bot, to Recipient, opt *SendOptions) (*Message, error b.embedSendOptions(params, opt) if d.FileSize != 0 { - params["file_size"] = strconv.Itoa(d.FileSize) + params["file_size"] = strconv.FormatInt(d.FileSize, 10) } if d.DisableTypeDetection { params["disable_content_type_detection"] = "true"