chamilo/chamilo-lms

View on GitHub
public/main/lp/lp_final_item.php

Summary

Maintainability
A
0 mins
Test Coverage

Missing class import via use statement (line '229', column '25').
Open

    $skillRelUser = new SkillRelUserModel();
Severity: Minor
Found in public/main/lp/lp_final_item.php by phpmd

MissingImport

Since: 2.7.0

Importing all external classes in a file through use statements makes them clearly visible.

Example

function make() {
    return new \stdClass();
}

Source http://phpmd.org/rules/cleancode.html#MissingImport

Avoid unused parameters such as '$courseCode'.
Open

    $courseCode,
Severity: Minor
Found in public/main/lp/lp_final_item.php by phpmd

UnusedFormalParameter

Since: 0.2

Avoid passing parameters to methods or constructors and then not using those parameters.

Example

class Foo
{
    private function bar($howdy)
    {
        // $howdy is not used
    }
}

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

Avoid unused parameters such as '$sessionId'.
Open

    $sessionId = 0,
Severity: Minor
Found in public/main/lp/lp_final_item.php by phpmd

UnusedFormalParameter

Since: 0.2

Avoid passing parameters to methods or constructors and then not using those parameters.

Example

class Foo
{
    private function bar($howdy)
    {
        // $howdy is not used
    }
}

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

Variable "_in_course" is not in valid camel caps format
Open

$_in_course = true;

Variable "current_course_tool" is not in valid camel caps format
Open

$current_course_tool = TOOL_GRADEBOOK;

Variable "show_message" is not in valid camel caps format
Open

            if (empty($show_message) && !api_is_allowed_to_edit() && !api_is_excluded_user_type()) {

Consider putting global function "generateLPFinalItemTemplateBadgeLinks" in a static class
Open

function generateLPFinalItemTemplateBadgeLinks($userId, $courseId, $sessionId = 0)

Variable "show_message" is not in valid camel caps format
Open

            $show_message = Category::show_message_resource_delete($courseId);

Consider putting global function "generateLPFinalItemTemplate" in a static class
Open

function generateLPFinalItemTemplate(

There are no issues that match your filters.

Category
Status