Cannot use_stored if type(photo) is not str
This commit is contained in:
parent
73b44a05d2
commit
12a5537291
@ -7,7 +7,7 @@ __author__ = "Davide Testa"
|
|||||||
__email__ = "davte@libero.it"
|
__email__ = "davte@libero.it"
|
||||||
__credits__ = "Marco Origlia"
|
__credits__ = "Marco Origlia"
|
||||||
__license__ = "GNU General Public License v3.0"
|
__license__ = "GNU General Public License v3.0"
|
||||||
__version__ = "1.4.3"
|
__version__ = "1.4.4"
|
||||||
__maintainer__ = "Davide Testa"
|
__maintainer__ = "Davide Testa"
|
||||||
__contact__ = "t.me/davte"
|
__contact__ = "t.me/davte"
|
||||||
|
|
||||||
|
@ -1489,6 +1489,8 @@ class Bot(telepot.aio.Bot, Gettable):
|
|||||||
) as photo_file:
|
) as photo_file:
|
||||||
buffered_picture.write(photo_file.read())
|
buffered_picture.write(photo_file.read())
|
||||||
photo = buffered_picture.getvalue()
|
photo = buffered_picture.getvalue()
|
||||||
|
else:
|
||||||
|
use_stored = False
|
||||||
caption = escape_html_chars(caption)
|
caption = escape_html_chars(caption)
|
||||||
if len(caption) > 199:
|
if len(caption) > 199:
|
||||||
new_caption = ''
|
new_caption = ''
|
||||||
|
Loading…
x
Reference in New Issue
Block a user