Skip to content

Commit 4d81ebb

Browse files
committed
minor fixes, closes #59
1 parent 3fb34af commit 4d81ebb

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/telebot/private/api.nim

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -329,9 +329,10 @@ proc sendInvoice*(b: TeleBot, chatId: int64, title: string, description: string,
329329
marshal(prices, json)
330330
data["prices"] = json
331331
if maxTipAmount != 0:
332-
data["max_tip_amount"] = maxTipAmount
332+
data["max_tip_amount"] = $maxTipAmount
333333
if suggestedTipAmounts.len != 0:
334-
json = marshal(suggestedTipAmounts, json)
334+
json = ""
335+
marshal(suggestedTipAmounts, json)
335336
data["suggested_top_amounts"] = json
336337
if startParameter.len != 0:
337338
data["start_parameter"] = startParameter

src/telebot/private/utils.nim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ proc newProcDef(name: string): NimNode {.compileTime.} =
223223
newStmtList()
224224
)
225225

226-
proc addData*(p: var MultipartData, name: string, content: auto, fileCheck = false) {.inline.} =
226+
proc addData*(p: var MultipartData, name: string, content: any, fileCheck = false) {.inline.} =
227227
when content is string:
228228
if fileCheck and content.startsWith("file://"):
229229
p.addFiles({name: content[7..content.len-1]})

0 commit comments

Comments
 (0)