mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-27 21:58:52 +00:00
[ticket/10392] Alter parent namespace stripping.
PHPBB3-10392
This commit is contained in:
parent
118bc6198e
commit
1f14013093
1 changed files with 9 additions and 2 deletions
|
@ -871,8 +871,15 @@ class phpbb_template_filter extends php_user_filter
|
|||
{
|
||||
// Strip the trailing period.
|
||||
$namespace = substr($namespace, 0, -1);
|
||||
$local_namespace = substr(strrchr($namespace, '.'), 1);
|
||||
$local_namespace = ($local_namespace) ? $local_namespace : $namespace;
|
||||
|
||||
if (($pos = strrpos($namespace, '.')) !== false)
|
||||
{
|
||||
$local_namespace = substr($namespace, $pos + 1);
|
||||
}
|
||||
else
|
||||
{
|
||||
$local_namespace = $namespace;
|
||||
}
|
||||
|
||||
$expr = true;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue