Showing 264 of 264 total issues

Avoid using static access to class '\Bavix\Helpers\Arr' in method 'buildWithoutCache'.
Open

            if (Arr::in([T_NEW, T_CLONE, T_INSTEADOF, T_INSTANCEOF, T_AS], $_token->type))
Severity: Minor
Found in src/Flow/Flow.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

Avoid using static access to class '\Bavix\Helpers\File' in method 'path'.
Open

        File::put($tmp, $code);
Severity: Minor
Found in tests/Unit.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

Avoid using static access to class '\Bavix\Helpers\Arr' in method 'buildWithoutCache'.
Open

                    Arr::push($code, '->');
Severity: Minor
Found in src/Flow/Flow.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

Avoid using static access to class '\Bavix\Helpers\Arr' in method 'configure'.
Open

        return Arr::merge(parent::configure(), [
            'cache' => $pool
        ]);
Severity: Minor
Found in tests/Flow/Directives/CacheTest.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

Avoid using static access to class '\Bavix\Helpers\Arr' in method 'buildWithoutCache'.
Open

                $pop = Arr::pop($code);
Severity: Minor
Found in src/Flow/Flow.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

Avoid using static access to class '\Bavix\Helpers\Str' in method 'buildWithoutCache'.
Open

                if (Str::ucFirst($_token->token) !== $_token->token &&
Severity: Minor
Found in src/Flow/Flow.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

Avoid using static access to class '\Bavix\Helpers\Arr' in method 'property'.
Open

                $extends = Arr::map((array)$prop['extends'], function ($extend) use ($self, &$props) {
                    return $self->property($props, $extend);
                });
Severity: Minor
Found in src/Flow/Lexeme.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

Avoid unused local variables such as '$prop'.
Open

        foreach ($props as $key => $prop)
Severity: Minor
Found in src/Flow/Lexeme.php by phpmd

UnusedLocalVariable

Since: 0.2

Detects when a local variable is declared and/or assigned, but not used.

Example

class Foo {
    public function doSomething()
    {
        $i = 5; // Unused
    }
}

Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable

Avoid using static access to class 'Bavix\Flow\Cache' in method 'tryLoad'.
Open

            $item = Cache::getItem(__CLASS__ . $key);
Severity: Minor
Found in src/Flow/Lexeme.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

Avoid using static access to class '\Bavix\Helpers\Str' in method 'path'.
Open

        $this->lastView = $view = 'flow__' . Str::random();
Severity: Minor
Found in tests/Unit.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

Avoid using static access to class '\Bavix\Helpers\File' in method 'path'.
Open

            @File::remove($tmp);
Severity: Minor
Found in tests/Unit.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

Avoid using static access to class '\Bavix\Helpers\Arr' in method 'buildWithoutCache'.
Open

                Arr::push($code, $pop);
Severity: Minor
Found in src/Flow/Flow.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

Avoid using static access to class '\Bavix\Helpers\Arr' in method 'buildWithoutCache'.
Open

                    (!$last || !Arr::in([
                            Validator::T_ENDBRACKET,
                            Validator::T_ENDARRAY,
                            Validator::T_DOT,
                            T_NS_SEPARATOR,
Severity: Minor
Found in src/Flow/Flow.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

Avoid using static access to class '\Bavix\Helpers\Arr' in method 'buildWithoutCache'.
Open

                if (!Arr::in([T_NEW, T_CLASS], $_token->type))
Severity: Minor
Found in src/Flow/Flow.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

Avoid using static access to class '\Bavix\Helpers\Arr' in method 'buildWithoutCache'.
Open

                ($last && !Arr::in([\T_DOUBLE_COLON, Validator::T_DOT], $last->type))) &&
Severity: Minor
Found in src/Flow/Flow.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

Avoid using static access to class '\Bavix\Helpers\Str' in method 'directive'.
Open

        $class = __NAMESPACE__ . '\\Directives\\' . Str::ucFirst($key) . 'Directive';
Severity: Minor
Found in src/Flow/Flow.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

Avoid using static access to class '\Bavix\Helpers\JSON' in method 'build'.
Open

        $_storeKey = __CLASS__ . JSON::encode($data);
Severity: Minor
Found in src/Flow/Flow.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

Avoid using static access to class '\Bavix\Helpers\Arr' in method 'buildWithoutCache'.
Open

                Arr::push($code, '\\' . WithDirective::class . '::last()');
Severity: Minor
Found in src/Flow/Flow.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

Avoid using static access to class '\Bavix\Helpers\Arr' in method 'buildWithoutCache'.
Open

                    Arr::pop($code);
Severity: Minor
Found in src/Flow/Flow.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

Avoid using static access to class '\Bavix\Helpers\Arr' in method 'buildWithoutCache'.
Open

            if (Arr::in([T_VARIABLE, T_FUNCTION], $_token->type))
Severity: Minor
Found in src/Flow/Flow.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

Severity
Category
Status
Source
Language