EscolaLMS/Webinar

View on GitHub
src/AuthServiceProvider.php

Summary

Maintainability
A
0 mins
Test Coverage
F
0%

Avoid using static access to class '\Laravel\Passport\Passport' in method 'boot'.
Open

            Passport::routes();
Severity: Minor
Found in src/AuthServiceProvider.php by phpmd

StaticAccess

Since: 1.4.0

Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

Example

class Foo
{
    public function bar()
    {
        Bar::baz();
    }
}

Source https://phpmd.org/rules/cleancode.html#staticaccess

Call to undeclared method \EscolaLms\Webinar\AuthServiceProvider::registerPolicies
Open

        $this->registerPolicies();
Severity: Critical
Found in src/AuthServiceProvider.php by phan

Call to method routes from undeclared class \Laravel\Passport\Passport
Open

            Passport::routes();
Severity: Critical
Found in src/AuthServiceProvider.php by phan

Reference to undeclared property \EscolaLms\Webinar\AuthServiceProvider->app
Open

        if (!$this->app->routesAreCached() && method_exists(Passport::class, 'routes')) {
Severity: Minor
Found in src/AuthServiceProvider.php by phan

Reference to constant class from undeclared class \Laravel\Passport\Passport
Open

        if (!$this->app->routesAreCached() && method_exists(Passport::class, 'routes')) {
Severity: Critical
Found in src/AuthServiceProvider.php by phan

Class extends undeclared class \Illuminate\Foundation\Support\Providers\AuthServiceProvider (Did you mean class \EscolaLms\Webinar\AuthServiceProvider)
Open

class AuthServiceProvider extends ServiceProvider
Severity: Critical
Found in src/AuthServiceProvider.php by phan

There are no issues that match your filters.

Category
Status