XoopsModules25x/apcal

View on GitHub

Showing 26,336 of 26,336 total issues

The parameter $from_lines is not named in camelCase.
Open

    public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
    {
        assert(count($from_lines) == count($mapped_from_lines));
        assert(count($to_lines) == count($mapped_to_lines));

Severity: Minor
Found in include/Text_Diff.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $mapped_from_lines is not named in camelCase.
Open

    public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
    {
        assert(count($from_lines) == count($mapped_from_lines));
        assert(count($to_lines) == count($mapped_to_lines));

Severity: Minor
Found in include/Text_Diff.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $to_lines is not named in camelCase.
Open

    public function diff($from_lines, $to_lines)
    {
        $n_from = count($from_lines);
        $n_to   = count($to_lines);

Severity: Minor
Found in include/Text_Diff.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

Avoid variables with short names like $yi. Configured minimum length is 3.
Open

        $xi = $yi = 0;
Severity: Minor
Found in include/Text_Diff.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

The parameter $from_lines is not named in camelCase.
Open

    public function diff($from_lines, $to_lines)
    {
        $n_from = count($from_lines);
        $n_to   = count($to_lines);

Severity: Minor
Found in include/Text_Diff.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The class Text_Diff_Op_add is not named in CamelCase.
Open

class Text_Diff_Op_add extends Text_Diff_Op
{
    /**
     * Text_Diff_Op_add constructor.
     * @param $lines
Severity: Minor
Found in include/Text_Diff.php by phpmd

CamelCaseClassName

Since: 0.2

It is considered best practice to use the CamelCase notation to name classes.

Example

class class_name {
}

Source

The class Text_Diff_Op_change is not named in CamelCase.
Open

class Text_Diff_Op_change extends Text_Diff_Op
{
    /**
     * Text_Diff_Op_change constructor.
     * @param $orig
Severity: Minor
Found in include/Text_Diff.php by phpmd

CamelCaseClassName

Since: 0.2

It is considered best practice to use the CamelCase notation to name classes.

Example

class class_name {
}

Source

The class Text_Diff_Engine_xdiff is not named in CamelCase.
Open

class Text_Diff_Engine_xdiff
{
    /**
     * @param $from_lines
     * @param $to_lines
Severity: Minor
Found in include/Text_Diff.php by phpmd

CamelCaseClassName

Since: 0.2

It is considered best practice to use the CamelCase notation to name classes.

Example

class class_name {
}

Source

Avoid variables with short names like $j. Configured minimum length is 3.
Open

        $j = 0;
Severity: Minor
Found in include/Text_Diff.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

The parameter $from_lines is not named in camelCase.
Open

    public function diff($from_lines, $to_lines)
    {
        /* Convert the two input arrays into strings for xdiff processing. */
        $from_string = implode("\n", $from_lines);
        $to_string   = implode("\n", $to_lines);
Severity: Minor
Found in include/Text_Diff.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $to_lines is not named in camelCase.
Open

    public function _check($from_lines, $to_lines)
    {
        if (serialize($from_lines) != serialize($this->getOriginal())) {
            trigger_error("Reconstructed original doesn't match", E_USER_ERROR);
        }
Severity: Minor
Found in include/Text_Diff.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $mapped_to_lines is not named in camelCase.
Open

    public function __construct($from_lines, $to_lines, $mapped_from_lines, $mapped_to_lines)
    {
        assert(count($from_lines) == count($mapped_from_lines));
        assert(count($to_lines) == count($mapped_to_lines));

Severity: Minor
Found in include/Text_Diff.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

Avoid variables with short names like $yi. Configured minimum length is 3.
Open

        $yi = $n_to;
Severity: Minor
Found in include/Text_Diff.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

The property $_trailing_context_lines is not named in camelCase.
Open

class Text_Diff_Renderer
{
    /**
     * Number of leading context "lines" to preserve.
     *
Severity: Minor
Found in include/Text_Diff_Renderer.php by phpmd

CamelCasePropertyName

Since: 0.2

It is considered best practice to use the camelCase notation to name attributes.

Example

class ClassName {
    protected $property_name;
}

Source

Avoid variables with short names like $fp. Configured minimum length is 3.
Open

            $fp = fopen($pname, 'r');
Severity: Minor
Found in include/patTemplate.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

Avoid variables with short names like $x1. Configured minimum length is 3.
Open

            $x1 = $xoff + (int)(($numer + ($xlim - $xoff) * $chunk) / $nchunks);
Severity: Minor
Found in include/Text_Diff.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

The class Text_Diff_Op_copy is not named in CamelCase.
Open

class Text_Diff_Op_copy extends Text_Diff_Op
{
    /**
     * Text_Diff_Op_copy constructor.
     * @param      $orig
Severity: Minor
Found in include/Text_Diff.php by phpmd

CamelCaseClassName

Since: 0.2

It is considered best practice to use the CamelCase notation to name classes.

Example

class class_name {
}

Source

The class Text_Diff_Renderer is not named in CamelCase.
Open

class Text_Diff_Renderer
{
    /**
     * Number of leading context "lines" to preserve.
     *
Severity: Minor
Found in include/Text_Diff_Renderer.php by phpmd

CamelCaseClassName

Since: 0.2

It is considered best practice to use the CamelCase notation to name classes.

Example

class class_name {
}

Source

The parameter $event_id is not named in camelCase.
Open

    function apcal_comments_update($event_id, $total_num)
    {
        // record total_num
        global $xoopsDB, $cal;

Severity: Minor
Found in include/comment_functions.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The property $_leading_context_lines is not named in camelCase.
Open

class Text_Diff_Renderer
{
    /**
     * Number of leading context "lines" to preserve.
     *
Severity: Minor
Found in include/Text_Diff_Renderer.php by phpmd

CamelCasePropertyName

Since: 0.2

It is considered best practice to use the camelCase notation to name attributes.

Example

class ClassName {
    protected $property_name;
}

Source

Severity
Category
Status
Source
Language