mirror of
https://github.com/flarum/framework.git
synced 2024-11-29 04:26:31 +08:00
Use singleton method
This commit is contained in:
parent
8c53a93d43
commit
b65d18ee7f
|
@ -30,8 +30,8 @@ class AdminServiceProvider extends ServiceProvider
|
||||||
*/
|
*/
|
||||||
public function register()
|
public function register()
|
||||||
{
|
{
|
||||||
$this->app['flarum.admin.assetManager'] = $this->app->share(function ($app) {
|
$this->app->singleton('flarum.admin.assetManager', function () {
|
||||||
return new AssetManager($app['files'], $app['path.public'].'/assets', 'admin');
|
return new AssetManager($this->app->make('files'), public_path('assets'), 'admin');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user