use think\Facade;
/**
* Class Queue
* @package think\facade
* @mixin \think\Queue
*/
class Queue extends Facade
{
protected static function getFacadeClass()
{
// return 'queue';
return 'think\queue';
}
}
原先的return 'queue';会报类不存在,需要return 'think\queue';才行,容器管理Container类中getAlias 根据别名获取真实类名没有将queue转变成think\queue
@流年
最佳答案