Gumarov1991/php-project-lvl2

View on GitHub

Showing 3 of 3 total issues

Method render has 30 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function render($data, $depth = 0)
{
    $indent = genIndent($depth, FIRST_INDENT);
    $arrResult = array_reduce($data, function ($acc, $value) use ($depth, $indent) {
        $status = $value['status'];
Severity: Minor
Found in src/Formatters/pretty.php - About 1 hr to fix

    Method render has 26 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function render($data, $path = '')
    {
        $arrResult = array_reduce($data, function ($acc, $value) use ($path) {
            $status = $value['status'];
            $name = $value['name'];
    Severity: Minor
    Found in src/Formatters/plain.php - About 1 hr to fix

      Method buildNode has 5 arguments (exceeds 4 allowed). Consider refactoring.
      Open

      function buildNode($nodeType, $name, $oldValue, $newValue, $children = [])
      Severity: Minor
      Found in src/gendiff.php - About 35 mins to fix
        Severity
        Category
        Status
        Source
        Language