Prechecker results: error


PHP lint problems

(0 errors, 0 warnings)

This section shows php lint problems in the code detected by php -l [More info]


PHP coding style problems

(43 errors, 27 warnings)

This section shows the coding style problems detected in the code by phpcs [More info]

mod/courselinks/backup/moodle2/backup_courselinks_stepslib.php
(#26) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
mod/courselinks/backup/moodle2/restore_courselinks_activity_task.class.php
(#73) Inline comments must start with a capital letter, digit or 3-dots sequence
(#73) This comment is 65% valid code; is this commented out code?
(#91) Inline comments must start with a capital letter, digit or 3-dots sequence
(#91) This comment is 69% valid code; is this commented out code?
mod/courselinks/backup/moodle2/restore_courselinks_stepslib.php
(#25) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
mod/courselinks/classes/event/course_module_viewed.php
(#26) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
(#47) File must end with a newline character
mod/courselinks/classes/output/mobile.php
(#62) Line exceeds 132 characters; contains 137 characters
mod/courselinks/classes/privacy/provider.php
(#26) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
mod/courselinks/db/mobile.php
(#43) File must end with a newline character
mod/courselinks/db/upgrade.php
(#43) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
(#99) File must end with a newline character
mod/courselinks/index.php
(#25) Expected login check (require_login, require_course_login, require_admin, admin_externalpage_setup) following config inclusion. None found.
(#32) File must end with a newline character
mod/courselinks/lang/en/courselinks.php
(#2) The opening <?php tag must be followed by exactly one newline.
(#30) Whitespace found at end of line within string
(#38) File must end with a newline character
mod/courselinks/lang/es/courselinks.php
(#2) The opening <?php tag must be followed by exactly one newline.
(#38) File must end with a newline character
mod/courselinks/lang/fr/courselinks.php
(#2) The opening <?php tag must be followed by exactly one newline.
(#38) File must end with a newline character
mod/courselinks/lib.php
(#27) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
(#36) Closing brace must be on a line by itself
(#37) Closing brace must be on a line by itself
(#38) Closing brace must be on a line by itself
(#39) Closing brace must be on a line by itself
(#40) Closing brace must be on a line by itself
(#41) Closing brace must be on a line by itself
(#42) Closing brace must be on a line by itself
(#43) Closing brace must be on a line by itself
(#44) Closing brace must be on a line by itself
(#45) Closing brace must be on a line by itself
(#46) Closing brace must be on a line by itself
(#156) Expected "try {\n...} catch (...) {\n"; found "try {\n...}\n catch (...) {\n"
(#184) Opening brace should be on the same line as the declaration
(#289) Variable "cards_by_line" must not contain underscores.
(#290) Variable "class_by_number" must not contain underscores.
(#307) Variable "class_by_number" must not contain underscores.
(#307) Variable "cards_by_line" must not contain underscores.
(#307) Line exceeds 132 characters; contains 172 characters
(#310) Line exceeds maximum limit of 180 characters; contains 181 characters
(#336) Line exceeds 132 characters; contains 143 characters
(#347) Line exceeds maximum limit of 180 characters; contains 210 characters
(#377) Line exceeds maximum limit of 180 characters; contains 194 characters
(#397) Usage of ELSEIF not allowed; use ELSE IF instead
(#400) Inline comments must start with a capital letter, digit or 3-dots sequence
(#400) This comment is 69% valid code; is this commented out code?
(#400) Line indented incorrectly; expected at least 8 spaces, found 0
(#400) Expected 1 space before comment text but found 8; use block comment if you need indentation
(#401) Line indented incorrectly; expected at least 8 spaces, found 0
(#401) Expected 1 space before comment text but found 8; use block comment if you need indentation
(#402) Line indented incorrectly; expected at least 8 spaces, found 0
(#402) Expected 1 space before comment text but found 8; use block comment if you need indentation
(#403) Line exceeds 132 characters; contains 140 characters
(#421) Line exceeds 132 characters; contains 150 characters
(#421) Inline comments must start with a capital letter, digit or 3-dots sequence
(#421) This comment is 65% valid code; is this commented out code?
(#470) Empty IF statement detected
(#473) Logical operator "and" is prohibited; use "&&" instead
(#484) Logical operator "and" is prohibited; use "&&" instead
(#485) Logical operator "and" is prohibited; use "&&" instead
(#560) Logical operator "and" is prohibited; use "&&" instead
(#577) Inline comments must end in full-stops, exclamation marks, or question marks
(#583) File must end with a newline character
mod/courselinks/mod_form.php
(#41) Visibility must be declared on method "definition"
(#100) Line exceeds 132 characters; contains 134 characters
(#126) Visibility must be declared on method "validation"
mod/courselinks/view.php
(#27) Inline comments must end in full-stops, exclamation marks, or question marks
(#57) File must end with a newline character

Javascript coding style problems

(0 errors, 0 warnings)

This section shows the coding style problems detected in the code by eslint [More info]


CSS problems

(0 errors, 0 warnings)

This section shows CSS problems detected by stylelint [More info]


PHPDocs style problems

(16 errors, 3 warnings)

This section shows the phpdocs problems detected in the code by local_moodlecheck [More info]

mod/courselinks/backup/moodle2/restore_courselinks_activity_task.class.php
(#17) No one-line description found in phpdocs for file
mod/courselinks/backup/moodle2/restore_courselinks_stepslib.php
(#17) No one-line description found in phpdocs for file
mod/courselinks/db/access.php
(#17) No one-line description found in phpdocs for file
mod/courselinks/lang/en/courselinks.php
(#2) Empty line found after PHP open tag
(#3) File-level phpdocs block is not found
mod/courselinks/lang/es/courselinks.php
(#2) Empty line found after PHP open tag
(#3) File-level phpdocs block is not found
mod/courselinks/lang/fr/courselinks.php
(#2) Empty line found after PHP open tag
(#3) File-level phpdocs block is not found
mod/courselinks/lib.php
(#31) Phpdocs for function courselinks_supports has incomplete parameters list
(#180) Phpdocs for function courselinks_get_courses_as_array has incomplete parameters list
(#232) Phpdocs for function courselinks_get_content has incomplete parameters list
(#281) Phpdocs for function courselinks_get_content_card has incomplete parameters list
(#328) Phpdocs for function courselinks_get_content_nav has incomplete parameters list
(#359) Phpdocs for function courselinks_get_content_list has incomplete parameters list
(#388) Phpdocs for function courselinks_get_html_link_options has incomplete parameters list
(#413) Phpdocs for function courselinks_get_course_image has incomplete parameters list
(#456) Phpdocs for function courselinks_has_access has incomplete parameters list
(#421) Invalid inline phpdocs tag @todo found

Update savepoints problems

(2 errors, 0 warnings)

This section shows problems detected with the handling of upgrade savepoints [More info]

mod/courselinks/db/upgrade.php
Detected more 'if' blocks (1) than 'savepoint' calls (0)
version 2022081800 is missing corresponding savepoint call

Third party library modification problems

(0 errors, 0 warnings)

This section shows problems detected with the modification of third party libraries [More info]


grunt changes

(0 errors, 0 warnings)

This section shows files built by grunt and not commited [More info]


shifter problems

(0 errors, 0 warnings)

This section shows problems detected by shifter [More info]


Mustache template problems

(0 errors, 1 warnings)

This section shows problems detected in mustache templates [More info]

mod/courselinks/templates/mobile_view.mustache
(#1) Example context missing.

Gherkin .feature problems

(0 errors, 0 warnings)

This section shows problems detected in behat .feature files [More info]