Details
-
Type:
Bug
-
Status: Open
-
Priority:
Minor
-
Resolution: Unresolved
-
Affects Version/s: 3.10
-
Fix Version/s: None
-
Component/s: Other
-
Labels:None
-
Affected Branches:MOODLE_310_STABLE
Description
There is a case where the class renaming in Moodle does not work well.
If you have a class with a name like: mod_myplugin_myclass and want to rename it to mod_myplugin/myclass and have a db/renamedclasses.php like:
$renamedclasses = [ |
'mod_myplugin_myclass' => 'mod_myplugin/myclass', |
];
|
Uses of mod_myplugin_myclass will result in a class not found exception, rather than a debugging message.
This seems to be happening because Moodle always generates both mod_myplugin_myclass and mod_myplugin/myclass in the valid mapping for each file found in the classes directory of plugins.