改名
This commit is contained in:
@@ -420,10 +420,10 @@ abstract class BaseActiveRecord extends Component implements IOrm, \ArrayAccess
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @param null $data
|
* @param null $data
|
||||||
* @return bool|BaseActiveRecord
|
* @return bool|$this
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
public function save($data = NULL): bool|static
|
public function save($data = NULL): static|bool
|
||||||
{
|
{
|
||||||
if (is_array($data)) {
|
if (is_array($data)) {
|
||||||
$this->setAttributes($data);
|
$this->setAttributes($data);
|
||||||
|
|||||||
@@ -27,13 +27,12 @@ class OnMessage extends Callback
|
|||||||
*/
|
*/
|
||||||
public function onHandler(Server $server, Frame $frame)
|
public function onHandler(Server $server, Frame $frame)
|
||||||
{
|
{
|
||||||
try {
|
|
||||||
if ($frame->opcode != 0x08) {
|
|
||||||
$event = Snowflake::app()->getEvent();
|
$event = Snowflake::app()->getEvent();
|
||||||
Coroutine::defer(function () use ($event) {
|
Coroutine::defer(function () use ($event) {
|
||||||
var_dump('Event::EVENT_AFTER_REQUEST');
|
|
||||||
$event->trigger(Event::EVENT_AFTER_REQUEST);
|
$event->trigger(Event::EVENT_AFTER_REQUEST);
|
||||||
});
|
});
|
||||||
|
try {
|
||||||
|
if ($frame->opcode != 0x08) {
|
||||||
$content = $this->resolve($event, $frame, $server);
|
$content = $this->resolve($event, $frame, $server);
|
||||||
if (!empty($content)) {
|
if (!empty($content)) {
|
||||||
$server->send($frame->fd, $content);
|
$server->send($frame->fd, $content);
|
||||||
|
|||||||
Reference in New Issue
Block a user