pug-php/pug-assets

View on GitHub
src/Pug/Assets.php

Summary

Maintainability
A
0 mins
Test Coverage
A
100%

Missing class import via use statement (line '32', column '23').
Open

            throw new \InvalidArgumentException(
Severity: Minor
Found in src/Pug/Assets.php by phpmd

MissingImport

Since: 2.7.0

Importing all external classes in a file through use statements makes them clearly visible.

Example

function make() {
    return new \stdClass();
}

Source http://phpmd.org/rules/cleancode.html#MissingImport

Property \Pug\Assets->pug has undeclared type \Pug\Pug
Open

    protected $pug;
Severity: Minor
Found in src/Pug/Assets.php by phan

Parameter $pug has undeclared type \Pug\Pug
Open

    public static function enable($pug)
Severity: Minor
Found in src/Pug/Assets.php by phan

Return type of getMinify() is undeclared type \Pug\Keyword\Minify
Open

    public function getMinify()
Severity: Minor
Found in src/Pug/Assets.php by phan

Call to method removeKeyword from undeclared class \Pug\Pug
Open

        $this->pug->removeKeyword('minify');
Severity: Critical
Found in src/Pug/Assets.php by phan

Call to method setKeyword from undeclared class \Pug\Pug
Open

        $this->pug->setKeyword('assets', $minify);
Severity: Critical
Found in src/Pug/Assets.php by phan

Returning type null but disable() is declared to return \Pug\Assets
Open

        return $assets;
Severity: Minor
Found in src/Pug/Assets.php by phan

Call to method setKeyword from undeclared class \Pug\Pug
Open

        $this->pug->setKeyword('concat-to', $minify);
Severity: Critical
Found in src/Pug/Assets.php by phan

Call to method removeKeyword from undeclared class \Pug\Pug
Open

        $this->pug->removeKeyword('concat-to');
Severity: Critical
Found in src/Pug/Assets.php by phan

Call to method __construct from undeclared class \Pug\Keyword\Minify
Open

        $this->setMinify(new Minify($pug));
Severity: Critical
Found in src/Pug/Assets.php by phan

Return type of getPug() is undeclared type \Pug\Pug
Open

    public function getPug()
Severity: Minor
Found in src/Pug/Assets.php by phan

Parameter $pug has undeclared type \Pug\Pug
Open

    public function __construct($pug)
Severity: Minor
Found in src/Pug/Assets.php by phan

Checking instanceof against undeclared class \Jade\Jade
Open

        if (!($pug instanceof \Jade\Jade) && !($pug instanceof \Pug\Pug) && !($pug instanceof \Phug\Renderer)) {
Severity: Critical
Found in src/Pug/Assets.php by phan

Call to method setKeyword from undeclared class \Pug\Pug
Open

        $this->pug->setKeyword('concat', $minify);
Severity: Critical
Found in src/Pug/Assets.php by phan

Checking instanceof against undeclared class \Phug\Renderer
Open

        if (!($pug instanceof \Jade\Jade) && !($pug instanceof \Pug\Pug) && !($pug instanceof \Phug\Renderer)) {
Severity: Critical
Found in src/Pug/Assets.php by phan

Call to method removeKeyword from undeclared class \Pug\Pug
Open

        $this->pug->removeKeyword('assets');
Severity: Critical
Found in src/Pug/Assets.php by phan

Checking instanceof against undeclared class \Pug\Pug
Open

        if (!($pug instanceof \Jade\Jade) && !($pug instanceof \Pug\Pug) && !($pug instanceof \Phug\Renderer)) {
Severity: Critical
Found in src/Pug/Assets.php by phan

Call to method setCustomOption from undeclared class \Pug\Pug
Open

        $this->pug->setCustomOption('environment', $environment);
Severity: Critical
Found in src/Pug/Assets.php by phan

Call to method setKeyword from undeclared class \Pug\Pug
Open

        $this->pug->setKeyword('minify', $minify);
Severity: Critical
Found in src/Pug/Assets.php by phan

Call to method removeKeyword from undeclared class \Pug\Pug
Open

        $this->pug->removeKeyword('minify-to');
Severity: Critical
Found in src/Pug/Assets.php by phan

Parameter $pug has undeclared type \Jade\Jade
Open

    public function __construct($pug)
Severity: Minor
Found in src/Pug/Assets.php by phan

Parameter $pug has undeclared type \Jade\Jade
Open

    public static function disable($pug)
Severity: Minor
Found in src/Pug/Assets.php by phan

Call to method getOption from undeclared class \Pug\Pug
Open

        return $this->pug->getOption('environment') ?: 'production';
Severity: Critical
Found in src/Pug/Assets.php by phan

Parameter $pug has undeclared type \Jade\Jade
Open

    public static function enable($pug)
Severity: Minor
Found in src/Pug/Assets.php by phan

Return type of getPug() is undeclared type \Pug\Jade
Open

    public function getPug()
Severity: Minor
Found in src/Pug/Assets.php by phan

Call to method setKeyword from undeclared class \Pug\Pug
Open

        $this->pug->setKeyword('minify-to', $minify);
Severity: Critical
Found in src/Pug/Assets.php by phan

Parameter $minify has undeclared type \Pug\Keyword\Minify
Open

    public function setMinify($minify)
Severity: Minor
Found in src/Pug/Assets.php by phan

Parameter $pug has undeclared type \Pug\Pug
Open

    public static function disable($pug)
Severity: Minor
Found in src/Pug/Assets.php by phan

Call to method removeKeyword from undeclared class \Pug\Pug
Open

        $this->pug->removeKeyword('concat');
Severity: Critical
Found in src/Pug/Assets.php by phan

Property \Pug\Assets->pug has undeclared type \Jade\Jade
Open

    protected $pug;
Severity: Minor
Found in src/Pug/Assets.php by phan

Property \Pug\Assets->minify has undeclared type \Pug\Keyword\Minify
Open

    protected $minify;
Severity: Minor
Found in src/Pug/Assets.php by phan

Assigning null to property but \Pug\Assets->minify is \Pug\Keyword\Minify
Open

        $this->minify = null;
Severity: Minor
Found in src/Pug/Assets.php by phan

There are no issues that match your filters.

Category
Status