Ken пре 1 недеља
родитељ
комит
3331905943
1 измењених фајлова са 9 додато и 0 уклоњено
  1. 9 0
      app/Services/QianBaoWithdrawService.php

+ 9 - 0
app/Services/QianBaoWithdrawService.php

@@ -399,6 +399,15 @@ class QianBaoWithdrawService
 
     static function inputCardNo($chatId, $cardNo, $messageId)
     {
+        if (!preg_match('/^\d+$/', $cardNo)) {
+            return [
+                'chat_id' => $chatId,
+                'text' => "输入有误,请重新输入",
+                'reply_to_message_id' => $messageId,
+            ];
+        }
+
+
         Cache::put("{$chatId}_QB_WITHDRAW_CARD_NO", $cardNo);
         Cache::put(get_step_key($chatId), StepStatus::QB_INPUT_ACCOUNT);