Added single-threaded and multi-threaded example
This commit is contained in:
parent
da6abceed2
commit
040426a63c
9 changed files with 110 additions and 15 deletions
10
tests/single_threaded.php
Normal file
10
tests/single_threaded.php
Normal file
|
@ -0,0 +1,10 @@
|
|||
<?php
|
||||
|
||||
require __DIR__ . DIRECTORY_SEPARATOR . 'autoload.php';
|
||||
|
||||
$bot = new TgBotLib\Bot(getenv('BOT_TOKEN'));
|
||||
|
||||
$bot->setCommandHandler('start', new \commands\StartCommand());
|
||||
$bot->setCommandHandler('hash', new \commands\HashCommand());
|
||||
|
||||
$bot->handleGetUpdates(true);
|
Loading…
Add table
Add a link
Reference in a new issue