User tests: Successful: Unsuccessful:
Pull Request for Issue #17413.
If the class contains a PSR 4 namespace the file location is not correctly compiled. This pr fixes that.
<?php
namespace App;
class Application
{
public static function loaded()
{
return 'LOADED!';
}
}
JLoader::registerNamespace('App',JPATH_SITE.DIRECTORY_SEPARATOR.'App',false,false,'psr4');
echo \App\Application::loaded();die;
String LOADED! is printed.
"Class 'App\Application' not found" error is displayed.
Category | ⇒ | Libraries |
Status | New | ⇒ | Pending |
I have tested this item
Steps:
Before Patch: like expected - "Class 'App\Application' not found" error is displayed.
After Patch: like exptected - String LOADED! is printed.
Tested @icampus
Thanks guys!
Status | Pending | ⇒ | Ready to Commit |
RTC after two successful tests.
Status | Ready to Commit | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2017-08-23 11:52:21 |
Closed_By | ⇒ | mbabker | |
Labels |
Added:
?
|
I have tested this item✅ successfully on 1eac297
For me it worked without the patch also, but the patch doesnt cause any errors
This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/17470.