diff --git a/modules/stars_bot.py b/modules/stars_bot.py index 8b5ac01..9d9996d 100644 --- a/modules/stars_bot.py +++ b/modules/stars_bot.py @@ -291,11 +291,13 @@ class TelegramStarsBot: await self.lolz_api.create_comment(post_id, reply_message) await asyncio.sleep(self.config.api_delay) - # Send ad as a separate comment if enabled + # Send ad as a separate comment wrapped in spoiler if enabled if self.config.enable_ads: ad_content = self.config._load_ads() if ad_content: - await self.lolz_api.create_comment(post_id, ad_content) + # Wrap ad in spoiler with align=center + ad_wrapped = f"[ad=align=center]{ad_content}[/ad]" + await self.lolz_api.create_comment(post_id, ad_wrapped) logger.info(f"Отправлена реклама к посту {post_id}") await asyncio.sleep(self.config.api_delay)