set timeout

fix: flood after reboot
This commit is contained in:
dennydai 2016-05-17 16:27:08 +08:00
parent 9ca2683657
commit 8eb00284f0

View File

@ -1,7 +1,6 @@
<?php <?php
$BOT = new Base; $BOT = new Base;
$GET = json_decode(file_get_contents("php://input"),true); $GET = json_decode(file_get_contents("php://input"),true);
$debug = file_get_contents("php://input");
//is group? //is group?
if ($GET['message']['chat']['id'] > 0) { if ($GET['message']['chat']['id'] > 0) {
@ -9,9 +8,15 @@ if ($GET['message']['chat']['id'] > 0) {
}else{ }else{
$isgroup = true; $isgroup = true;
} }
//reply to... //reply to...
$msgid = $GET['message']['message_id']; $msgid = $GET['message']['message_id'];
$from = $GET['message']['chat']['id']; $from = $GET['message']['chat']['id'];
$date = $GET['message']['date'];
if ((time() - $date) > 120) {
$text = 'unset';
}else {
$text = $GET['message']['text']; $text = $GET['message']['text'];
}
define('MSGID',$msgid); define('MSGID',$msgid);