调整LogicTrait

This commit is contained in:
liaofei 2019-12-27 09:37:42 +08:00
parent 0a2a19a72f
commit 94e0d06744

View File

@ -23,17 +23,6 @@ trait LogicTrait
*/
protected static $instance;
/**
* 静态方法调用
* @param $method 调用方法
* @param $params 参数
* @return mixed
*/
public static function __callStatic($method, $params)
{
return call_user_func_array([self::$instance, $method], $params);
}
/**
* 配置参数
* @param array $config
@ -171,8 +160,12 @@ trait LogicTrait
return $this;
}
} else if (in_array($method, $keys)) {
$this->sendType = $method;
if (property_exists($this, 'handleType') && array_shift($ages) !== true) {
$this->handleType = $method;
return $this;
} else {
return $this->{$method};
}
} else {
throw new AuthException('Method does not exist' . $method);
}