From 1d892f7d090a1ff91f724871e688b18a40df768e Mon Sep 17 00:00:00 2001 From: Nikita Kiselev Date: Wed, 6 Aug 2025 20:38:22 +0300 Subject: [PATCH] feat: do not check signature if bot token not set --- .../framework/Telegram/SignatureValidator.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/module/oc_telegram_shop/upload/oc_telegram_shop/framework/Telegram/SignatureValidator.php b/module/oc_telegram_shop/upload/oc_telegram_shop/framework/Telegram/SignatureValidator.php index 1d9d322..1f475bc 100755 --- a/module/oc_telegram_shop/upload/oc_telegram_shop/framework/Telegram/SignatureValidator.php +++ b/module/oc_telegram_shop/upload/oc_telegram_shop/framework/Telegram/SignatureValidator.php @@ -15,6 +15,10 @@ class SignatureValidator public function validate(Request $request): void { + if (! $this->botToken) { + return; + } + $initDataString = rawurldecode($request->header('X-Telegram-Initdata')); if (! $initDataString) {