EasySmsServiceProvider 中 register 函数为什么有个 $App 无用变量?
为什么要传$app这个无用变量?代表什么意思呢?
public function register()
{
$this->app->singleton(EasySms::class, function ($app) {
return new EasySms(config('easysms'));
});
$this->app->alias(EasySms::class, 'easysms');
}
推荐文章: