chamilo/chamilo-lms

View on GitHub
src/CourseBundle/Entity/CWikiCategory.php

Summary

Maintainability
A
0 mins
Test Coverage

Avoid unused private fields such as '$lft'.
Open

    private int $lft = 0;

UnusedPrivateField

Since: 0.2

Detects when a private field is declared and/or assigned a value, but not used.

Example

class Something
{
    private static $FOO = 2; // Unused
    private $i = 5; // Unused
    private $j = 6;
    public function addOne()
    {
        return $this->j++;
    }
}

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

Avoid unused private fields such as '$rgt'.
Open

    private int $rgt = 0;

UnusedPrivateField

Since: 0.2

Detects when a private field is declared and/or assigned a value, but not used.

Example

class Something
{
    private static $FOO = 2; // Unused
    private $i = 5; // Unused
    private $j = 6;
    public function addOne()
    {
        return $this->j++;
    }
}

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

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[ORM\Entity]

You must use "/**" style comments for a class comment
Open

class CWikiCategory

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Id]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[Gedmo\TreeParent]

Add a single space around assignment operators
Open

declare(strict_types=1);

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\ManyToOne(targetEntity: Course::class)]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\ManyToOne(targetEntity: self::class)]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\JoinColumn(name: 'tree_root', referencedColumnName: 'id', onDelete: 'CASCADE')]

Missing function doc comment
Open

    public function setCourse(Course $course): self

Missing function doc comment
Open

    public function getParent(): ?self

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'id', type: 'integer')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[Gedmo\TreeRight]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'rgt', type: 'integer')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\ManyToOne(targetEntity: self::class, inversedBy: 'children')]

Missing function doc comment
Open

    public function getCourse(): Course

Missing function doc comment
Open

    public function getRoot(): ?self

Missing function doc comment
Open

    public function setParent(?self $parent): self

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\GeneratedValue]

Missing function doc comment
Open

    public function setChildren(Collection $children): self

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[ORM\Table(name: 'c_wiki_category')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'title', type: 'string')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\JoinColumn(name: 'session_id', referencedColumnName: 'id', onDelete: 'CASCADE')]

Missing function doc comment
Open

    public function getTitle(): string

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'lvl', type: 'integer')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\ManyToOne(targetEntity: Session::class)]

Missing function doc comment
Open

    public function __construct()

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\JoinColumn(name: 'c_id', referencedColumnName: 'id', nullable: false, onDelete: 'CASCADE')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'lft', type: 'integer')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\OrderBy(['lft' => 'ASC'])]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[Gedmo\TreeLeft]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\JoinColumn(name: 'parent_id', referencedColumnName: 'id', onDelete: 'CASCADE')]

Missing function doc comment
Open

    public function __toString(): string

Missing function doc comment
Open

    public function setTitle(string $title): self

Missing function doc comment
Open

    public function getSession(): ?Session

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\ManyToMany(targetEntity: CWiki::class, mappedBy: 'categories')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[Gedmo\TreeLevel]

Missing function doc comment
Open

    public function setSession(?Session $session): self

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[Gedmo\Tree(type: 'nested')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\OneToMany(mappedBy: 'parent', targetEntity: self::class)]

Missing function doc comment
Open

    public function getId(): ?int

Missing function doc comment
Open

    public function getNodeName(): string

Missing function doc comment
Open

    public function addWikiPage(CWiki $page): self

There are no issues that match your filters.

Category
Status