Skip to content

Commit

Permalink
fixbug
Browse files Browse the repository at this point in the history
  • Loading branch information
kiss291323003 committed Mar 7, 2019
1 parent 42d7c61 commit 00c8d6b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/Core.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,9 +119,9 @@ function createServer()
$conf['PORT'],$conf['SERVER_TYPE'],$conf['LISTEN_ADDRESS'],$conf['SETTING'],$conf['RUN_MODEL'],$conf['SOCK_TYPE']
);
$this->registerDefaultCallBack(ServerManager::getInstance()->getSwooleServer(),$conf['SERVER_TYPE']);
$this->extraHandler();
//hook 全局的mainServerCreate事件
EasySwooleEvent::mainServerCreate(ServerManager::getInstance()->getMainEventRegister());
$this->extraHandler();
return $this;
}

Expand Down Expand Up @@ -386,7 +386,7 @@ private function extraHandler()
{
$serverName = Config::getInstance()->getConf('SERVER_NAME');

//注册console,子端口需要提前注册,避免在mainServerCreate被注册后覆盖冲突
//注册Console
if(Config::getInstance()->getConf('CONSOLE.ENABLE')){
$config = Config::getInstance()->getConf('CONSOLE');
ServerManager::getInstance()->addServer('CONSOLE',$config['PORT'],SWOOLE_TCP,$config['LISTEN_ADDRESS']);
Expand Down
2 changes: 1 addition & 1 deletion src/SysConst.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

class SysConst
{
const EASYSWOOLE_VERSION = '3.1.17-dev';
const EASYSWOOLE_VERSION = '3.1.16';
const LOGGER_HANDLER = 'LOGGER_HANDLER';
const ERROR_HANDLER = 'ERROR_HANDLER';
const TRIGGER_HANDLER = 'TRIGGER_HANDLER';
Expand Down

0 comments on commit 00c8d6b

Please sign in to comment.