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

(79 errors, 66 warnings)

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

blocks/my_enrolled_courses/block_my_enrolled_courses.php
(#34) global $PAGE cannot be used in block classes. Use $this->page.
(#35) global $PAGE cannot be used in block classes. Use $this->page.
(#36) global $PAGE cannot be used in block classes. Use $this->page.
(#48) Short array syntax must be used to define arrays
blocks/my_enrolled_courses/db/access.php
(#27) Short array syntax must be used to define arrays
(#29) Short array syntax must be used to define arrays
(#32) Short array syntax must be used to define arrays
(#33) There should be a comma after the last array item in a multi-line array.
(#36) There should be a comma after the last array item in a multi-line array.
(#39) Short array syntax must be used to define arrays
(#44) Short array syntax must be used to define arrays
(#46) There should be a comma after the last array item in a multi-line array.
(#49) There should be a comma after the last array item in a multi-line array.
(#50) There should be a comma after the last array item in a multi-line array.
blocks/my_enrolled_courses/db/services.php
(#25) Expected MOODLE_INTERNAL check or config.php inclusion. Change in global state detected.
(#25) Short array syntax must be used to define arrays
(#26) Short array syntax must be used to define arrays
(#27) Short array syntax must be used to define arrays
(#31) There should be a comma after the last array item in a multi-line array.
(#33) Short array syntax must be used to define arrays
(#34) Short array syntax must be used to define arrays
(#41) There should be a comma after the last array item in a multi-line array.
(#42) There should be a comma after the last array item in a multi-line array.
(#43) File must end with a newline character
blocks/my_enrolled_courses/db/upgrade.php
(#1) End of line character is invalid; expected "\n" but found "\r\n"
(#26) Whitespace found at end of line
(#28) Whitespace found at end of line
(#34) Short array syntax must be used to define arrays
(#35) Short array syntax must be used to define arrays
(#41) Whitespace found at end of line
(#43) File must end with a newline character
blocks/my_enrolled_courses/externallib.php
(#33) Expected 8 space(s) before asterisk; 5 found
(#34) Expected 8 space(s) before asterisk; 5 found
(#35) Expected 8 space(s) before asterisk; 5 found
(#38) Short array syntax must be used to define arrays
(#39) There should be a comma after the last array item in a multi-line array.
(#48) Short array syntax must be used to define arrays
(#52) Short array syntax must be used to define arrays
(#74) File must end with a newline character
blocks/my_enrolled_courses/locallib.php
(#1) End of line character is invalid; expected "\n" but found "\r\n"
(#31) Short array syntax must be used to define arrays
(#33) Short array syntax must be used to define arrays
(#34) Short array syntax must be used to define arrays
(#39) Variable "courses_diff" must not contain underscores.
(#40) Expected "if (...) {\n"; found "if(...) {\n"
(#40) Variable "courses_diff" must not contain underscores.
(#62) Short array syntax must be used to define arrays
(#72) Short array syntax must be used to define arrays
(#73) Short array syntax must be used to define arrays
(#86) Short array syntax must be used to define arrays
(#106) Short array syntax must be used to define arrays
(#111) Short array syntax must be used to define arrays
(#117) Whitespace found at end of line
(#123) Short array syntax must be used to define arrays
(#124) Whitespace found at end of line
(#126) Spaces must be used to indent lines; tabs are not allowed
(#126) Tab found within whitespace
(#126) Line indented incorrectly; expected at least 8 spaces, found 4
(#126) Short array syntax must be used to define arrays
(#127) Spaces must be used to indent lines; tabs are not allowed
(#127) Tab found within whitespace
(#127) Line indented incorrectly; expected at least 8 spaces, found 4
(#128) Spaces must be used to indent lines; tabs are not allowed
(#128) Tab found within whitespace
(#128) Line indented incorrectly; expected at least 8 spaces, found 4
(#130) Whitespace found at end of line
(#140) Short array syntax must be used to define arrays
(#145) Short array syntax must be used to define arrays
(#158) Short array syntax must be used to define arrays
(#162) Short array syntax must be used to define arrays
(#178) Short array syntax must be used to define arrays
(#179) Short array syntax must be used to define arrays
(#184) Short array syntax must be used to define arrays
(#186) Spaces must be used to indent lines; tabs are not allowed
(#186) Tab found within whitespace
(#186) Line indented incorrectly; expected at least 8 spaces, found 6
(#189) Short array syntax must be used to define arrays
(#190) Short array syntax must be used to define arrays
(#192) Commas (,) must be followed by white space.
(#192) Short array syntax must be used to define arrays
(#192) Expected 1 space before "=>"; 0 found
(#192) Expected 1 space after "=>"; 0 found
(#192) Expected 1 space before "=>"; 0 found
(#192) Expected 1 space after "=>"; 0 found
(#192) Expected 1 space before "=>"; 0 found
(#192) Expected 1 space after "=>"; 0 found
(#193) Short array syntax must be used to define arrays
(#193) Expected 1 space before "=>"; 0 found
(#193) Expected 1 space after "=>"; 0 found
(#198) Short array syntax must be used to define arrays
(#204) Short array syntax must be used to define arrays
(#215) Variable "mod_info" must not contain underscores.
(#217) Expected "if (...) {\n"; found "if(...) {\n"
(#217) Variable "mod_info" must not contain underscores.
(#218) Short array syntax must be used to define arrays
(#219) Short array syntax must be used to define arrays
(#220) Expected "foreach (...) {\n"; found "foreach(...) {\n"
(#220) Variable "mod_info" must not contain underscores.
(#221) Expected "if (...) {\n"; found "if(...) {\n"
(#222) Short array syntax must be used to define arrays
(#223) Variable "mod_url" must not contain underscores.
(#224) Expected "if (...) {\n"; found "if(...) {\n"
(#225) Spaces must be used to indent lines; tabs are not allowed
(#225) Tab found within whitespace
(#225) Line indented incorrectly; expected at least 20 spaces, found 17
(#225) Variable "mod_url" must not contain underscores.
(#227) Spaces must be used to indent lines; tabs are not allowed
(#227) Tab found within whitespace
(#227) Line indented incorrectly; expected at least 20 spaces, found 17
(#227) Variable "mod_url" must not contain underscores.
(#229) Variable "mod_url" must not contain underscores.
(#242) Whitespace found at end of line
(#243) Short array syntax must be used to define arrays
(#244) Expected "if (...) {\n"; found "if(...) {\n"
(#249) Whitespace found at end of line
(#250) Short array syntax must be used to define arrays
(#251) Short array syntax must be used to define arrays
(#255) Short array syntax must be used to define arrays
(#260) Short array syntax must be used to define arrays
(#261) Expected "if (...) {\n"; found "if(...) {\n"
(#266) Expected "if (...) {\n"; found "if(...) {\n"
blocks/my_enrolled_courses/showhide.php
(#1) End of line character is invalid; expected "\n" but found "\r\n"
(#31) Short array syntax must be used to define arrays
(#33) Short array syntax must be used to define arrays
(#73) Short array syntax must be used to define arrays
(#74) Short array syntax must be used to define arrays
(#76) Short array syntax must be used to define arrays
(#77) Short array syntax must be used to define arrays
(#79) Short array syntax must be used to define arrays
(#81) Short array syntax must be used to define arrays
(#88) Short array syntax must be used to define arrays
(#93) Short array syntax must be used to define arrays
(#94) Short array syntax must be used to define arrays
(#96) Short array syntax must be used to define arrays
(#97) There should be a comma after the last array item in a multi-line array.
(#99) Short array syntax must be used to define arrays
(#101) Short array syntax must be used to define arrays
(#102) There should be a comma after the last array item in a multi-line array.
(#106) Short array syntax must be used to define arrays
(#108) Short array syntax must be used to define arrays
(#115) Short array syntax must be used to define arrays
(#123) Short array syntax must be used to define arrays
(#123) Expected 1 space before "=>"; 0 found
(#123) Expected 1 space after "=>"; 0 found
(#130) File must end with a newline character

Javascript coding style problems

(7 errors, 41 warnings)

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

blocks/my_enrolled_courses/amd/src/myenrolledcourses.js
(#1) There should be no space before this paren. (space-in-parens)
(#2) Expected space(s) after "return". (keyword-spacing)
(#3) Missing space before opening brace. (space-before-blocks)
(#4) Trailing spaces not allowed. (no-trailing-spaces)
(#6) 'evt' is defined but never used. (no-unused-vars)
(#6) 'info' is defined but never used. (no-unused-vars)
(#10) Unnecessary escape character: \". (no-useless-escape)
(#13) Expected space(s) after "if". (keyword-spacing)
(#13) Use '===' to compare with null. (no-eq-null)
(#13) There should be no space before this paren. (space-in-parens)
(#13) Missing space before opening brace. (space-before-blocks)
(#15) Expected space(s) after "if". (keyword-spacing)
(#15) Operator '!=' must be spaced. (space-infix-ops)
(#16) Expected { after 'if' condition. (curly)
(#16) Unnecessary escape character: \". (no-useless-escape)
(#16) Unnecessary escape character: \". (no-useless-escape)
(#17) Multiple spaces found before 'JSON'. (no-multi-spaces)
(#18) Unexpected space after unary operator '++'. (space-unary-ops)
(#21) Unnecessary escape character: \". (no-useless-escape)
(#23) 'promises' is assigned a value but never used. (no-unused-vars)
(#29) Trailing spaces not allowed. (no-trailing-spaces)
(#32) There should be no space after this paren. (space-in-parens)
(#32) There should be no space before this paren. (space-in-parens)
(#33) There should be no space after this paren. (space-in-parens)
(#33) There should be no space before this paren. (space-in-parens)
(#34) There should be no space after this paren. (space-in-parens)
(#34) There should be no space before this paren. (space-in-parens)
(#35) There should be no space after this paren. (space-in-parens)
(#35) There should be no space before this paren. (space-in-parens)
(#35) There should be no space after this paren. (space-in-parens)
(#35) There should be no space before this paren. (space-in-parens)
(#35) There should be no space after this paren. (space-in-parens)
(#35) There should be no space before this paren. (space-in-parens)
(#36) Expected space(s) after "if". (keyword-spacing)
(#36) There should be no space after this paren. (space-in-parens)
(#36) There should be no space before this paren. (space-in-parens)
(#37) There should be no space after this paren. (space-in-parens)
(#37) There should be no space before this paren. (space-in-parens)
(#37) There should be no space after this paren. (space-in-parens)
(#37) There should be no space before this paren. (space-in-parens)
(#38) Expected space(s) after "if". (keyword-spacing)
(#38) There should be no space after this paren. (space-in-parens)
(#38) There should be no space before this paren. (space-in-parens)
(#39) There should be no space after this paren. (space-in-parens)
(#39) There should be no space before this paren. (space-in-parens)
(#39) There should be no space after this paren. (space-in-parens)
(#39) There should be no space before this paren. (space-in-parens)
(#43) Missing space before opening brace. (space-before-blocks)

CSS problems

(30 errors, 0 warnings)

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

blocks/my_enrolled_courses/style.css
(#31) Expected newline before "}" (block-closing-brace-newline-before)
(#67) Expected newline before "}" (block-closing-brace-newline-before)
(#13) Expected newline after "{" (block-opening-brace-newline-after)
(#77) Expected single space before "{" (block-opening-brace-space-before)
(#80) Expected single space before "{" (block-opening-brace-space-before)
(#86) Expected single space before "{" (block-opening-brace-space-before)
(#2) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#5) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#5) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#22) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#22) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#25) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#28) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#34) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#34) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#37) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#40) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#40) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#58) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#58) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#61) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#64) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#70) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#70) Expected newline after ";" in a multi-line declaration block (declaration-block-semicolon-newline-after)
(#31) Unexpected whitespace at end of line (no-eol-whitespace)
(#67) Unexpected whitespace at end of line (no-eol-whitespace)
(#4) Expected newline after "," (selector-list-comma-newline-after)
(#18) Expected newline after "," (selector-list-comma-newline-after)
(#39) Expected newline after "," (selector-list-comma-newline-after)
(#54) Expected newline after "," (selector-list-comma-newline-after)

PHPDocs style problems

(10 errors, 3 warnings)

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

blocks/my_enrolled_courses/block_my_enrolled_courses.php
(#28) Class block_my_enrolled_courses is not documented
(#29) Function block_my_enrolled_courses::init is not documented
(#33) Function block_my_enrolled_courses::get_content is not documented
blocks/my_enrolled_courses/db/upgrade.php
(#17) File-level phpdocs block is not found
(#17) Phpdocs for function xmldb_block_my_enrolled_courses_upgrade has incomplete parameters list
blocks/my_enrolled_courses/externallib.php
(#45) Function moodle_my_enrolled_courses_shorting_external::my_enrolled_courses_shorting is not documented
blocks/my_enrolled_courses/locallib.php
(#26) Function block_my_enrolled_courses_show_courses is not documented
(#56) Function block_my_enrolled_courses_hide_courses is not documented
(#102) Function block_my_enrolled_courses_get_visible_courses is not documented
(#136) Function block_my_enrolled_courses_get_hidden_courses is not documented
(#173) Function block_my_enrolled_courses_visible_in_block is not documented
(#212) Function block_my_enrolled_courses_course_modules is not documented
(#240) Function block_my_enrolled_courses_manage_courses is not documented

Update savepoints problems

(0 errors, 0 warnings)

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


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

(1 errors, 1 warnings)

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

Problems running grunt
Task "eslint:amd" failed. Use --force to continue.

shifter problems

(0 errors, 0 warnings)

This section shows problems detected by shifter [More info]


Mustache template problems

(0 errors, 0 warnings)

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


Gherkin .feature problems

(0 errors, 0 warnings)

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