diff --git a/bot.rb b/bot.rb index e411b04..e7edd7f 100644 --- a/bot.rb +++ b/bot.rb @@ -173,37 +173,7 @@ def isTextMethod(message,bot) $bot_is=bot puts "telegram bot started" bot.listen do |message| - if $STOP==0 - case message - when Telegram::Bot::Types::Message - puts message - if $STOP==0 - if message.text!="/stop" - $msgChId = message.chat.id - #puts "message: #{message}" - # if message.text != - if message.photo!=[] - #puts "#{message.photo}" - puts "salam" - $isText=0 - $isPhoto=1 - end - - $msg=message - checkLogStatus - - $isText=1 - $codeVar = message.text - if $codeVar.length>6 && message.text.include?("/start") - $codeVar= $codeVar.delete_prefix("/start ") - $message_orig = $data_hash["#{$codeVar}"] - $showMsg=1 - end - isTextMethod(message,bot) - end - end - end - end + end end