Issues (19)

src/ServiceProvider.php (1 issue)

Labels
Severity
1
<?php
2
3
namespace Fomvasss\MediaLibraryExtension;
4
5
class ServiceProvider extends \Illuminate\Support\ServiceProvider
6
{
7
    /**
8
     * Bootstrap the application services.
9
     *
10
     * @return void
11
     */
12
    public function boot()
13
    {
14
        $this->publishes([
15
            __DIR__.'/../config/medialibrary-extension.php' => config_path('medialibrary-extension.php')
0 ignored issues
show
The function config_path was not found. Maybe you did not declare it correctly or list all dependencies? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

15
            __DIR__.'/../config/medialibrary-extension.php' => /** @scrutinizer ignore-call */ config_path('medialibrary-extension.php')
Loading history...
16
        ], 'config');
17
    }
18
19
    /**
20
     * Register the application services.
21
     *
22
     * @return void
23
     */
24
    public function register()
25
    {
26
        $this->mergeConfigFrom(__DIR__.'/../config/medialibrary-extension.php', 'medialibrary-extension');
27
28
        $this->app->singleton(MediaLibraryManager::class, function () {
29
            return new MediaLibraryManager();
30
        });
31
32
        $this->app->alias(MediaLibraryManager::class, 'medialibrary-manager');
33
    }
34
}
35