FIX: fix duplicate :: in template names
This commit is contained in:
@@ -68,7 +68,7 @@ class TemplateRegistrator
|
|||||||
*/
|
*/
|
||||||
public function setNamespace($namespace)
|
public function setNamespace($namespace)
|
||||||
{
|
{
|
||||||
$this->namespace = $namespace . '::';
|
$this->namespace = $namespace;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -102,6 +102,9 @@ class TemplateRegistrator
|
|||||||
$this->unsetNamespace();
|
$this->unsetNamespace();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Save templates into database
|
||||||
|
*/
|
||||||
public function saveTemplates()
|
public function saveTemplates()
|
||||||
{
|
{
|
||||||
if (!is_array($this->paths) || empty($this->paths)) {
|
if (!is_array($this->paths) || empty($this->paths)) {
|
||||||
@@ -109,7 +112,7 @@ class TemplateRegistrator
|
|||||||
}
|
}
|
||||||
|
|
||||||
foreach ($this->paths as $path) {
|
foreach ($this->paths as $path) {
|
||||||
$this->setNamespace($path['namespace']);
|
$this->setNamespace($path['namespace'] . '::');
|
||||||
$this->setModuleId($path['moduleId']);
|
$this->setModuleId($path['moduleId']);
|
||||||
$this->setBaseDirectory($path['baseDirectory']);
|
$this->setBaseDirectory($path['baseDirectory']);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user