mirror of
https://github.com/danog/telegram-bot-bash.git
synced 2024-11-26 20:15:02 +01:00
FIxing bugs
This commit is contained in:
parent
43c468e336
commit
905d68a9f3
@ -72,7 +72,7 @@ send_keyboard() {
|
||||
local keyboard=init
|
||||
OLDIFS=$IFS
|
||||
IFS=$(echo -en "\"")
|
||||
for f in $*;do [ ! -z "$f" ] && local keyboard="$keyboard, [\"$f\"]";done
|
||||
for f in $*;do [ "$f" != " " ] && local keyboard="$keyboard, [\"$f\"]";done
|
||||
IFS=$OLDIFS
|
||||
local keyboard=${keyboard/init, /}
|
||||
res=$(curl -s "$MSG_URL" --header "content-type: multipart/form-data" -F "chat_id=$chat" -F "text=$text" -F "reply_markup={\"keyboard\": [$keyboard],\"one_time_keyboard\": true}")
|
||||
|
Loading…
Reference in New Issue
Block a user