From d8b8693a4358a8dca5f40198f2f839e729b79ac9 Mon Sep 17 00:00:00 2001 From: Ceda EI Date: Tue, 3 Apr 2018 19:23:53 +0530 Subject: [PATCH] Remove reply from send_code function. --- update_chain.php | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/update_chain.php b/update_chain.php index 50d118a..9b46939 100644 --- a/update_chain.php +++ b/update_chain.php @@ -7,20 +7,11 @@ if ($conn->connect_error) { die("Connection failed: " . $conn->connect_error); } -function send_code($post_message, $reply=false) { - global $decoded; +function send_code($post_message) { global $bot_api; global $chat_id; $url = 'https://api.telegram.org/bot' . $bot_api . '/sendMessage'; $post_msg = array('chat_id' => $chat_id, 'text' => '```\n ' . $post_message . '```', 'parse_mode' => 'markdown' ); - if ($reply != false) { - if ($reply === true){ - $post_msg['reply_to_message_id'] = $decoded->{'message'}->{'message_id'}; - } - else { - $post_msg['reply_to_message_id'] = $reply; - } - } $options = array( 'http' => array( 'header' => "Content-type: application/x-www-form-urlencoded\r\n",