改名
This commit is contained in:
+33
-1
@@ -201,7 +201,7 @@ if (!function_exists('fire')) {
|
||||
* @throws ComponentException
|
||||
* @throws Exception
|
||||
*/
|
||||
function fire(string $event,array $params = [])
|
||||
function fire(string $event, array $params = [])
|
||||
{
|
||||
$logger = Snowflake::app()->getEvent();
|
||||
$logger->trigger($event, $params);
|
||||
@@ -584,3 +584,35 @@ if (!function_exists('jTraceEx')) {
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
if (!function_exists('swoole_substr_json_decode')) {
|
||||
|
||||
|
||||
/**
|
||||
* @param $packet
|
||||
* @param int $length
|
||||
* @return mixed
|
||||
*/
|
||||
function swoole_substr_json_decode($packet, $length = 0)
|
||||
{
|
||||
return json_decode($packet, true);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
if (!function_exists('swoole_substr_unserialize')) {
|
||||
|
||||
|
||||
/**
|
||||
* @param $packet
|
||||
* @param int $length
|
||||
* @return mixed
|
||||
*/
|
||||
function swoole_substr_unserialize($packet, $length = 0)
|
||||
{
|
||||
return unserialize($packet);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user