1
0
mirror of https://github.com/eternnoir/pyTelegramBotAPI.git synced 2023-08-10 21:12:57 +03:00
This commit is contained in:
_run 2022-08-13 14:40:20 +05:00
parent 2647a02fc6
commit ffb34da610
2 changed files with 5 additions and 9 deletions

View File

@ -4281,10 +4281,8 @@ class TeleBot:
"""
if contains_masks is not None:
logger.warning('The parameter "contains_masks" is deprecated, use "sticker_type" instead')
if contains_masks:
sticker_type = 'mask'
else:
sticker_type = 'regular'
if sticker_type is None:
sticker_type = 'mask' if contains_masks else 'regular'
return apihelper.create_new_sticker_set(
self.token, user_id, name, title, emojis, png_sticker, tgs_sticker,

View File

@ -5119,10 +5119,8 @@ class AsyncTeleBot:
"""
if contains_masks is not None:
logger.warning('The parameter "contains_masks" is deprecated, use "sticker_type" instead')
if contains_masks:
sticker_type = 'mask'
else:
sticker_type = 'regular'
if sticker_type is None:
sticker_type = 'mask' if contains_masks else 'regular'
return await asyncio_helper.create_new_sticker_set(
self.token, user_id, name, title, emojis, png_sticker, tgs_sticker,