Add type declaration to reply_user

This commit is contained in:
2018-12-21 19:50:06 +07:00
parent 5095f347a0
commit 1adf272d2a

View File

@@ -18,12 +18,13 @@ $handlers = array(
new TestHandler() new TestHandler()
); );
function reply_user($room_id, $msgid, $message, $room_lang) function reply_user(int $room_id, int $msgid, string $message, $room_lang): bool
{ {
global $handlers; global $handlers;
foreach ($handlers as $handler) { foreach ($handlers as $handler) {
if($handler->TryHandle($room_id, $msgid, $message, $room_lang)) { if($handler->TryHandle($room_id, $msgid, $message, $room_lang)) {
break; return true;
} }
} }
return false;
} }