Merge branch 'patch-1' of git://github.com/juanmal/telegram-bot into juanmal-patch-1
This commit is contained in:
commit
54203f7dbd
@ -47,8 +47,8 @@ function run(msg, matches)
|
||||
|
||||
-- remove images
|
||||
local images = {}
|
||||
if response.entities.media then
|
||||
for k, v in pairs(response.entities.media) do
|
||||
if response.extended_entities.media then
|
||||
for k, v in pairs(response.extended_entities.media) do
|
||||
local url = v.url
|
||||
local pic = v.media_url
|
||||
text = text:gsub(url, "")
|
||||
@ -62,6 +62,7 @@ function run(msg, matches)
|
||||
for k, v in pairs(images) do
|
||||
local file = download_to_file(v)
|
||||
send_photo(receiver, file, ok_cb, false)
|
||||
delay_s(1)
|
||||
end
|
||||
|
||||
return nil
|
||||
|
Reference in New Issue
Block a user