src/Pug/Engine/OptionsHandler.php

Summary

Maintainability
A
0 mins
Test Coverage
A
100%

Avoid using undefined variables such as '$start' which will lead to PHP notices.
Open

                return [$token[1], $start, $end];
Severity: Minor
Found in src/Pug/Engine/OptionsHandler.php by phpmd

UndefinedVariable

Since: 2.8.0

Detects when a variable is used that has not been defined before.

Example

class Foo
{
    private function bar()
    {
        // $message is undefined
        echo $message;
    }
}

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

Avoid using undefined variables such as '$start' which will lead to PHP notices.
Open

            if ($this->getNamespaceOffsets($token, $afterNamespace, $start, $end)) {
Severity: Minor
Found in src/Pug/Engine/OptionsHandler.php by phpmd

UndefinedVariable

Since: 2.8.0

Detects when a variable is used that has not been defined before.

Example

class Foo
{
    private function bar()
    {
        // $message is undefined
        echo $message;
    }
}

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

Avoid using undefined variables such as '$end' which will lead to PHP notices.
Open

        foreach ($this->filterNamespaceStringTokens($tokens, $afterNamespace, $start, $end) as $token) {
Severity: Minor
Found in src/Pug/Engine/OptionsHandler.php by phpmd

UndefinedVariable

Since: 2.8.0

Detects when a variable is used that has not been defined before.

Example

class Foo
{
    private function bar()
    {
        // $message is undefined
        echo $message;
    }
}

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

Avoid using undefined variables such as '$afterNamespace' which will lead to PHP notices.
Open

        foreach ($this->filterNamespaceStringTokens($tokens, $afterNamespace, $start, $end) as $token) {
Severity: Minor
Found in src/Pug/Engine/OptionsHandler.php by phpmd

UndefinedVariable

Since: 2.8.0

Detects when a variable is used that has not been defined before.

Example

class Foo
{
    private function bar()
    {
        // $message is undefined
        echo $message;
    }
}

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

Avoid using undefined variables such as '$end' which will lead to PHP notices.
Open

            if ($this->getNamespaceOffsets($token, $afterNamespace, $start, $end)) {
Severity: Minor
Found in src/Pug/Engine/OptionsHandler.php by phpmd

UndefinedVariable

Since: 2.8.0

Detects when a variable is used that has not been defined before.

Example

class Foo
{
    private function bar()
    {
        // $message is undefined
        echo $message;
    }
}

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

Avoid using undefined variables such as '$afterNamespace' which will lead to PHP notices.
Open

            if ($this->getNamespaceOffsets($token, $afterNamespace, $start, $end)) {
Severity: Minor
Found in src/Pug/Engine/OptionsHandler.php by phpmd

UndefinedVariable

Since: 2.8.0

Detects when a variable is used that has not been defined before.

Example

class Foo
{
    private function bar()
    {
        // $message is undefined
        echo $message;
    }
}

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

Avoid using undefined variables such as '$end' which will lead to PHP notices.
Open

                return [$token[1], $start, $end];
Severity: Minor
Found in src/Pug/Engine/OptionsHandler.php by phpmd

UndefinedVariable

Since: 2.8.0

Detects when a variable is used that has not been defined before.

Example

class Foo
{
    private function bar()
    {
        // $message is undefined
        echo $message;
    }
}

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

Avoid using undefined variables such as '$start' which will lead to PHP notices.
Open

        foreach ($this->filterNamespaceStringTokens($tokens, $afterNamespace, $start, $end) as $token) {
Severity: Minor
Found in src/Pug/Engine/OptionsHandler.php by phpmd

UndefinedVariable

Since: 2.8.0

Detects when a variable is used that has not been defined before.

Example

class Foo
{
    private function bar()
    {
        // $message is undefined
        echo $message;
    }
}

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

Parameter $event has undeclared type \Phug\Compiler\Event\OutputEvent
Open

        $options['on_output'] = function (OutputEvent $event) use ($onOutput, $postRender) {
Severity: Minor
Found in src/Pug/Engine/OptionsHandler.php by phan

Call to undeclared method \Pug\Engine\OptionsHandler::addOptionNameHandlers
Open

        $this->addOptionNameHandlers(function ($name) {
Severity: Critical
Found in src/Pug/Engine/OptionsHandler.php by phan

Call to method setInput from undeclared class \Phug\Lexer\Event\LexEvent
Open

                $event->setInput(call_user_func($preRender, $event->getInput()));
Severity: Critical
Found in src/Pug/Engine/OptionsHandler.php by phan

Call to method getOutput from undeclared class \Phug\Compiler\Event\OutputEvent
Open

            $output = $event->getOutput();
Severity: Critical
Found in src/Pug/Engine/OptionsHandler.php by phan

Call to method setOutput from undeclared class \Phug\Compiler\Event\OutputEvent
Open

            $event->setOutput($output);
Severity: Critical
Found in src/Pug/Engine/OptionsHandler.php by phan

Parameter $event has undeclared type \Phug\Lexer\Event\LexEvent
Open

            $options['on_lex'] = function (LexEvent $event) use ($onLex, $preRender) {
Severity: Minor
Found in src/Pug/Engine/OptionsHandler.php by phan

Call to method getInput from undeclared class \Phug\Lexer\Event\LexEvent
Open

                $event->setInput(call_user_func($preRender, $event->getInput()));
Severity: Critical
Found in src/Pug/Engine/OptionsHandler.php by phan

There are no issues that match your filters.

Category
Status