Skip to content

Commit 1ee48e9

Browse files
Merge pull request #2 from LordDeveloper/v1.0.0
Updated
2 parents a5620d3 + 3dd7d61 commit 1ee48e9

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

src/Events/Handler.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ class Handler
2020
{
2121
const UPDATE_TYPE_WEBHOOK = 1;
2222
const UPDATE_TYPE_POLLING = 2;
23-
const UPDATE_TYPE_SOCKET_SERVER = 3;
23+
const UPDATE_TYPE_HTTP_SERVER = 3;
2424

2525
public static array $eventHandlers = [];
2626

src/TelegramAPI.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ public function hear(int $updateType = Handler::UPDATE_TYPE_WEBHOOK, string $uri
230230
exit();
231231
});
232232
break;
233-
case Handler::UPDATE_TYPE_SOCKET_SERVER:
233+
case Handler::UPDATE_TYPE_HTTP_SERVER:
234234
$options = getopt('d::', [
235235
'drop_pending_updates::'
236236
]);

src/Utils/Logger/Logger.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
use Psr\Log\LoggerTrait;
1010
use Psr\Log\LogLevel;
1111
use Throwable;
12+
use function Amp\ByteStream\getOutputBufferStream;
1213
use function Botify\array_some;
1314
use function Botify\base_path;
1415
use function Botify\config;
@@ -93,7 +94,7 @@ public function log($level, $message, array $context = []): void
9394
}
9495

9596
if ($this->type & static::ECHO_TYPE) {
96-
\Botify\file_put_contents('php://output', Colorize::log($level, $log));
97+
getOutputBufferStream()->write(Colorize::log($level, $log));
9798
}
9899

99100
if ($this->type & static::FILE_TYPE) {

0 commit comments

Comments
 (0)