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

(175 errors, 42 warnings)

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

enrol/dbuserrel/classes/dataport_external.php
(#25) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
(#155) Curly brace syntax for accessing array elements and string offsets has been deprecated in PHP 7.4. Found: $this->remote{$source}
(#253) Inline comments must end in full-stops, exclamation marks, or question marks
(#264) Logical operator "or" is prohibited; use "||" instead
(#283) Logical operator "or" is prohibited; use "||" instead
enrol/dbuserrel/classes/dataport_factory.php
(#25) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
enrol/dbuserrel/classes/dataport_interface.php
(#25) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
enrol/dbuserrel/classes/dataport_internal.php
(#25) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
enrol/dbuserrel/classes/field/profile.php
(#27) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
(#87) Expected 1 space after "=>"; 2 found
(#141) Inline comments must end in full-stops, exclamation marks, or question marks
(#165) File must end with a newline character
enrol/dbuserrel/classes/field/user.php
(#27) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
enrol/dbuserrel/classes/field_factory.php
(#25) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
enrol/dbuserrel/classes/field_interface.php
(#17) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
enrol/dbuserrel/classes/syncstrategy/defaultstrategy.php
(#27) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
(#111) Spaces must be used to indent lines; tabs are not allowed
(#111) Tab found within whitespace
(#111) Line indented incorrectly; expected at least 24 spaces, found 21
(#121) Spaces must be used to indent lines; tabs are not allowed
(#121) Tab found within whitespace
(#121) Line indented incorrectly; expected at least 24 spaces, found 21
(#122) Spaces must be used to indent lines; tabs are not allowed
(#122) Tab found within whitespace
(#122) Expected 1 space after "=>"; 2 found
(#123) Spaces must be used to indent lines; tabs are not allowed
(#123) Tab found within whitespace
(#123) Line indented incorrectly; expected 20 spaces, found 17
(#123) Closing brace indented incorrectly; expected 20 spaces, found 17
(#131) Spaces must be used to indent lines; tabs are not allowed
(#131) Tab found within whitespace
(#131) Line indented incorrectly; expected 24 spaces, found 21
(#132) Spaces must be used to indent lines; tabs are not allowed
(#132) Tab found within whitespace
(#132) Line indented incorrectly; expected at least 28 spaces, found 25
(#133) Spaces must be used to indent lines; tabs are not allowed
(#133) Tab found within whitespace
(#133) Expected 1 space after "=>"; 2 found
(#134) Spaces must be used to indent lines; tabs are not allowed
(#134) Tab found within whitespace
(#134) Line indented incorrectly; expected 24 spaces, found 21
(#147) Spaces must be used to indent lines; tabs are not allowed
(#147) Tab found within whitespace
(#147) Line indented incorrectly; expected 24 spaces, found 21
(#148) Spaces must be used to indent lines; tabs are not allowed
(#148) Tab found within whitespace
(#148) Line indented incorrectly; expected at least 28 spaces, found 26
(#149) Spaces must be used to indent lines; tabs are not allowed
(#149) Tab found within whitespace
(#149) Expected 1 space after "=>"; 2 found
(#150) Spaces must be used to indent lines; tabs are not allowed
(#150) Tab found within whitespace
(#150) Line indented incorrectly; expected 24 spaces, found 21
(#162) Spaces must be used to indent lines; tabs are not allowed
(#162) Tab found within whitespace
(#162) Line indented incorrectly; expected 16 spaces, found 4
(#163) Spaces must be used to indent lines; tabs are not allowed
(#163) Tab found within whitespace
(#163) Line indented incorrectly; expected at least 20 spaces, found 17
(#164) Spaces must be used to indent lines; tabs are not allowed
(#164) Tab found within whitespace
(#164) Expected 1 space after "=>"; 2 found
(#165) Spaces must be used to indent lines; tabs are not allowed
(#165) Tab found within whitespace
(#165) Line indented incorrectly; expected 16 spaces, found 4
(#179) Spaces must be used to indent lines; tabs are not allowed
(#179) Tab found within whitespace
(#179) Line indented incorrectly; expected 12 spaces, found 3
(#180) Spaces must be used to indent lines; tabs are not allowed
(#180) Tab found within whitespace
(#180) Line indented incorrectly; expected at least 16 spaces, found 13
(#181) Spaces must be used to indent lines; tabs are not allowed
(#181) Tab found within whitespace
(#181) Line indented incorrectly; expected 12 spaces, found 9
(#181) Closing brace indented incorrectly; expected 3 spaces, found 9
(#187) Spaces must be used to indent lines; tabs are not allowed
(#187) Tab found within whitespace
(#187) Line indented incorrectly; expected 20 spaces, found 17
(#188) Spaces must be used to indent lines; tabs are not allowed
(#188) Tab found within whitespace
(#188) Line indented incorrectly; expected at least 24 spaces, found 21
(#189) Closing brace indented incorrectly; expected 17 spaces, found 20
enrol/dbuserrel/classes/syncstrategy_interface.php
(#25) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
(#59) File must end with a newline character
enrol/dbuserrel/classes/task/dbuserrel_sync.php
(#28) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
enrol/dbuserrel/cli/sync.php
(#37) Spaces must be used to indent lines; tabs are not allowed
(#37) Tab found within whitespace
(#37) Whitespace found at end of line
(#48) Spaces must be used to indent lines; tabs are not allowed
(#48) Tab found within whitespace
(#48) Line indented incorrectly; expected at least 4 spaces, found 1
(#49) Spaces must be used to indent lines; tabs are not allowed
(#49) Tab found within whitespace
(#49) Line indented incorrectly; expected at least 4 spaces, found 1
(#54) Line indented incorrectly; expected at least 4 spaces, found 0
(#65) Spaces must be used to indent lines; tabs are not allowed
(#65) Tab found within whitespace
(#66) Spaces must be used to indent lines; tabs are not allowed
(#66) Tab found within whitespace
(#70) Spaces must be used to indent lines; tabs are not allowed
(#70) Tab found within whitespace
(#70) Line indented incorrectly; expected at least 4 spaces, found 1
(#71) Spaces must be used to indent lines; tabs are not allowed
(#71) Tab found within whitespace
(#74) Expected "if (...) {\n"; found "if (...){\n"
(#75) The use of function error_log() is forbidden; use debugging() instead
(#78) Spaces must be used to indent lines; tabs are not allowed
(#78) Tab found within whitespace
(#78) Whitespace found at end of line
(#79) Spaces must be used to indent lines; tabs are not allowed
(#79) Tab found within whitespace
(#79) Whitespace found at end of line
(#83) Spaces must be used to indent lines; tabs are not allowed
(#83) Tab found within whitespace
(#83) Whitespace found at end of line
(#85) File must end with a newline character
enrol/dbuserrel/db/tasks.php
(#38) File must end with a newline character
enrol/dbuserrel/lang/fr/enrol_dbuserrel.php
(#2) Line 1 of the opening comment must start "// This file is part of".
(#2) Line 2 of the opening comment must start "//".
(#2) Line 3 of the opening comment must start "// Moodle is free software: you can redistribute it and/or modify".
(#2) Line 4 of the opening comment must start "// it under the terms of the GNU General Public License as published by".
(#2) Line 5 of the opening comment must start "// the Free Software Foundation, either version 3 of the License, or".
(#2) Line 6 of the opening comment must start "// (at your option) any later version.".
(#2) Line 7 of the opening comment must start "//".
(#2) Line 8 of the opening comment must start "// Moodle is distributed in the hope that it will be useful,".
(#2) Line 9 of the opening comment must start "// but WITHOUT ANY WARRANTY; without even the implied warranty of".
(#2) Line 10 of the opening comment must start "// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the".
(#3) Line 11 of the opening comment must start "// GNU General Public License for more details.".
(#3) Line 12 of the opening comment must start "//".
(#3) Line 13 of the opening comment must start "// You should have received a copy of the GNU General Public License".
(#3) Line 14 of the opening comment must start "// along with Moodle. If not, see <http://www.gnu.org/licenses/>.".
enrol/dbuserrel/lib.php
(#30) Unexpected MOODLE_INTERNAL check. No side effects or multiple artifacts detected.
(#39) The 'var' keyword is not permitted.Visibility must be explicitly declared with public, private or protected
(#39) Scope modifier not specified for member variable "$log"
(#68) The use of function error_log() is forbidden; use debugging() instead
(#83) Logical operator "or" is prohibited; use "||" instead
(#83) Logical operator "or" is prohibited; use "||" instead
(#83) Logical operator "or" is prohibited; use "||" instead
(#83) Logical operator "or" is prohibited; use "||" instead
(#83) Line exceeds maximum limit of 180 characters; contains 201 characters
(#87) No space found before comment text; expected "// TODO: connect to external system and make sure no users are to be enrolled in this course." but found "//TODO: connect to external system and make sure no users are to be enrolled in this course."
(#98) Line exceeds 132 characters; contains 134 characters
(#121) Visibility must be declared on method "setup_enrolments"
(#122) Expected "try {\n...} catch (...) {\n"; found "try {\n...} catch(...) {\n"
(#126) Spaces must be used to indent lines; tabs are not allowed
(#126) Tab found within whitespace
(#126) Line indented incorrectly; expected at least 16 spaces, found 13
enrol/dbuserrel/settings.php
(#1) End of line character is invalid; expected "\n" but found "\r\n"
(#2) Line 1 of the opening comment must start "// This file is part of".
(#2) Line 2 of the opening comment must start "//".
(#3) Line 3 of the opening comment must start "// Moodle is free software: you can redistribute it and/or modify".
(#3) Line 4 of the opening comment must start "// it under the terms of the GNU General Public License as published by".
(#3) Line 5 of the opening comment must start "// the Free Software Foundation, either version 3 of the License, or".
(#3) Line 6 of the opening comment must start "// (at your option) any later version.".
(#3) Line 7 of the opening comment must start "//".
(#4) Line 8 of the opening comment must start "// Moodle is distributed in the hope that it will be useful,".
(#4) Line 9 of the opening comment must start "// but WITHOUT ANY WARRANTY; without even the implied warranty of".
(#4) Line 10 of the opening comment must start "// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the".
(#5) Line 11 of the opening comment must start "// GNU General Public License for more details.".
(#5) Line 12 of the opening comment must start "//".
(#5) Line 13 of the opening comment must start "// You should have received a copy of the GNU General Public License".
(#5) Line 14 of the opening comment must start "// along with Moodle. If not, see <http://www.gnu.org/licenses/>.".
(#15) Inline comments must start with a capital letter, digit or 3-dots sequence
(#15) Line indented incorrectly; expected at least 4 spaces, found 0
(#15) No space found before comment text; expected "// --- general settings -----------------------------------------------------------------------------------" but found "//--- general settings -----------------------------------------------------------------------------------"
(#20) Commas (,) must be followed by white space.
(#20) Line exceeds maximum limit of 180 characters; contains 374 characters
(#30) Line exceeds 132 characters; contains 175 characters
(#34) Line exceeds 132 characters; contains 134 characters
(#38) Line exceeds 132 characters; contains 137 characters
(#39) Whitespace found at end of line
(#40) Line exceeds maximum limit of 180 characters; contains 196 characters
(#42) Line exceeds 132 characters; contains 138 characters
(#44) Inline comments must end in full-stops, exclamation marks, or question marks
(#61) Line exceeds maximum limit of 180 characters; contains 200 characters
(#61) Spaces must be used for alignment; tabs are not allowed
(#61) Tab found within whitespace
(#61) Whitespace found at end of line
(#63) Line exceeds maximum limit of 180 characters; contains 215 characters
(#63) Spaces must be used for alignment; tabs are not allowed
(#63) Tab found within whitespace
(#63) Whitespace found at end of line
(#65) Line exceeds maximum limit of 180 characters; contains 213 characters
(#65) Spaces must be used for alignment; tabs are not allowed
(#65) Tab found within whitespace
(#65) Whitespace found at end of line
(#67) Line exceeds maximum limit of 180 characters; contains 193 characters
enrol/dbuserrel/tests/dbuserrel_test.php
(#40) PHPUnit testcase name "enrol_dbuserrel_testcase" does not match file name "dbuserrel_test"
(#40) PHPUnit class "enrol_dbuserrel_testcase" does not have any namespace. It is recommended to add it to the "enrol_dbuserrel" namespace, using more levels if needed, in order to match the code being tested
(#55) Inline comments must end in full-stops, exclamation marks, or question marks
(#78) Commas (,) must be followed by white space.
(#80) Inline comments must end in full-stops, exclamation marks, or question marks
(#83) Inline comments must start with a capital letter, digit or 3-dots sequence
(#83) This comment is 58% valid code; is this commented out code?
(#90) Inline comments must end in full-stops, exclamation marks, or question marks
(#93) Inline comments must start with a capital letter, digit or 3-dots sequence
(#93) This comment is 58% valid code; is this commented out code?
(#100) Inline comments must end in full-stops, exclamation marks, or question marks
(#108) Inline comments must end in full-stops, exclamation marks, or question marks
(#125) Opening brace should be on the same line as the declaration
enrol/dbuserrel/version.php
(#2) Line 1 of the opening comment must start "// This file is part of".
(#2) Line 2 of the opening comment must start "//".
(#3) Line 3 of the opening comment must start "// Moodle is free software: you can redistribute it and/or modify".
(#3) Line 4 of the opening comment must start "// it under the terms of the GNU General Public License as published by".
(#3) Line 5 of the opening comment must start "// the Free Software Foundation, either version 3 of the License, or".
(#3) Line 6 of the opening comment must start "// (at your option) any later version.".
(#3) Line 7 of the opening comment must start "//".
(#4) Line 8 of the opening comment must start "// Moodle is distributed in the hope that it will be useful,".
(#4) Line 9 of the opening comment must start "// but WITHOUT ANY WARRANTY; without even the implied warranty of".
(#4) Line 10 of the opening comment must start "// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the".
(#5) Line 11 of the opening comment must start "// GNU General Public License for more details.".
(#5) Line 12 of the opening comment must start "//".
(#5) Line 13 of the opening comment must start "// You should have received a copy of the GNU General Public License".
(#5) Line 14 of the opening comment must start "// along with Moodle. If not, see <http://www.gnu.org/licenses/>.".
(#14) Inline comments must end in full-stops, exclamation marks, or question marks
(#15) Inline comments must end in full-stops, exclamation marks, or question marks
(#17) Inline comments must end in full-stops, exclamation marks, or question marks

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

(73 errors, 0 warnings)

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

enrol/dbuserrel/classes/dataport_external.php
(#120) There is no description in phpdocs for function get_relationships_in_scope
(#149) There is no description in phpdocs for function get_equivalent_moodle_id
(#158) There is no description in phpdocs for function get_all_roles
(#171) There is no description in phpdocs for function get_role_fieldname
(#178) There is no description in phpdocs for function get_subject_fieldname
(#185) There is no description in phpdocs for function get_object_fieldname
(#192) There is no description in phpdocs for function sanitise_literal_for_comparison
(#258) There is no description in phpdocs for function db_encode
(#277) There is no description in phpdocs for function db_decode
(#296) There is no description in phpdocs for function db_addslashes
(#311) There is no description in phpdocs for function get_remote_subject
(#318) There is no description in phpdocs for function set_remote_subject
(#325) There is no description in phpdocs for function get_remote_object
(#332) There is no description in phpdocs for function set_remote_object
(#200) Phpdocs for function enrol_dbuserrel_dataport_external::init_external_db has incomplete parameters list
(#259) Phpdocs for function enrol_dbuserrel_dataport_external::db_encode has incomplete parameters list
(#278) Phpdocs for function enrol_dbuserrel_dataport_external::db_decode has incomplete parameters list
(#297) Phpdocs for function enrol_dbuserrel_dataport_external::db_addslashes has incomplete parameters list
enrol/dbuserrel/classes/dataport_internal.php
(#92) There is no description in phpdocs for function get_all_roles
(#101) There is no description in phpdocs for function get_role_fieldname
(#108) There is no description in phpdocs for function get_subject_fieldname
(#115) There is no description in phpdocs for function get_object_fieldname
(#122) There is no description in phpdocs for function get_relationships_in_scope
(#178) There is no description in phpdocs for function get_equivalent_moodle_id
(#202) There is no description in phpdocs for function get_local_object
(#209) There is no description in phpdocs for function set_local_object
(#216) There is no description in phpdocs for function get_local_subject
(#223) There is no description in phpdocs for function set_local_subject
enrol/dbuserrel/classes/field/profile.php
(#31) Package enrol_dbuserrel\field is not valid
(#63) There is no description in phpdocs for function get_field_name
(#73) There is no description in phpdocs for function translate_moodle_userid_to_mapped_value
(#94) There is no description in phpdocs for function get_equivalent_moodle_id
(#159) There is no description in phpdocs for function set_mappable_profile_fields
enrol/dbuserrel/classes/field/user.php
(#31) Package enrol_dbuserrel\field is not valid
(#38) Function user::__construct is not documented
(#35) Variable user::$field is not documented
(#36) Variable user::$mappableprofilefields is not documented
(#45) There is no description in phpdocs for function get_field_name
(#52) There is no description in phpdocs for function translate_moodle_userid_to_mapped_value
(#72) There is no description in phpdocs for function get_equivalent_moodle_id
(#92) There is no description in phpdocs for function get_mappable_profile_fields
enrol/dbuserrel/classes/field_interface.php
(#33) Package is not specified for function __construct. It is also not specified in file-level phpdocs
(#40) Package is not specified for function get_equivalent_moodle_id. It is also not specified in file-level phpdocs
(#48) Package is not specified for function get_field_name. It is also not specified in file-level phpdocs
(#55) Package is not specified for function translate_moodle_userid_to_mapped_value. It is also not specified in file-level phpdocs
(#63) Package is not specified for function get_mappable_profile_fields. It is also not specified in file-level phpdocs
(#36) Phpdocs for function __construct has incomplete parameters list
enrol/dbuserrel/classes/privacy/provider.php
(#19) Package is not specified for class provider. It is also not specified in file-level phpdocs
(#19) Class provider is not documented
enrol/dbuserrel/classes/syncstrategy/defaultstrategy.php
(#42) Function defaultstrategy::__construct is not documented
(#39) Variable defaultstrategy::$externaldataport is not documented
(#40) Variable defaultstrategy::$internaldataport is not documented
(#29) No one-line description found in phpdocs for class defaultstrategy
enrol/dbuserrel/cli/sync.php
(#29) Package enrol is not valid
enrol/dbuserrel/lang/en/enrol_dbuserrel.php
(#17) File-level phpdocs block is not found
enrol/dbuserrel/lang/fr/enrol_dbuserrel.php
(#2) File-level phpdocs block is not found
enrol/dbuserrel/lib.php
(#22) Package enrol is not valid
(#32) Class enrol_dbuserrel_plugin is not documented
(#41) Function enrol_dbuserrel_plugin::setup is not documented
(#148) Function enrol_dbuserrel_plugin::get_internal_dataport is not documented
(#152) Function enrol_dbuserrel_plugin::set_internal_dataport is not documented
(#156) Function enrol_dbuserrel_plugin::get_external_dataport is not documented
(#160) Function enrol_dbuserrel_plugin::set_external_dataport is not documented
(#34) Variable enrol_dbuserrel_plugin::$externaldataport is not documented
(#35) Variable enrol_dbuserrel_plugin::$internaldataport is not documented
(#37) Variable enrol_dbuserrel_plugin::$syncstrategy is not documented
(#39) Variable enrol_dbuserrel_plugin::$log is not documented
enrol/dbuserrel/settings.php
(#5) Package enrol is not valid
enrol/dbuserrel/tests/dbuserrel_test.php
(#124) Function enrol_dbuserrel_testcase::create_remote_source is not documented
(#145) Function enrol_dbuserrel_testcase::remove_remote_source is not documented
(#42) Variable enrol_dbuserrel_testcase::$remotetablename is not documented
(#43) Variable enrol_dbuserrel_testcase::$dbuserrelplugin is not documented
enrol/dbuserrel/version.php
(#5) Package enrol is not valid

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]


Missing changes in external functions or backup support for new detected tables or columns

(0 errors, 0 warnings)

This section shows potential problems detected when there are new database structures added in a patch and it is detected that nothing has been changed related with external functions (to be used by WS) or backup and restore. It must be checked that everything is correct and nothing is being missed in those areas. [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, 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]