This commit is contained in:
conory 2018-01-29 23:38:19 +09:00
parent 913ccf4a3c
commit 28dfc44a86
2 changed files with 4 additions and 4 deletions

View file

@ -252,10 +252,10 @@ class HTMLDisplayHandler
$oModuleController = getController('module');
$oModuleController->replaceDefinedLangCode($output);
// remove comment tag
if(Context::get('logged_info')->is_admin !== 'Y')
// remove template path comment tag
if(!Rhymix\Framework\Debug::isEnabledForCurrentUser())
{
$output = preg_replace('/\n?<!--[^\[].*?-->/s', '', $output);
$output = preg_replace('/\n?<!--\s?Template.*?-->\n?/', '', $output);
}
}

View file

@ -359,7 +359,7 @@ class TemplateHandler
}
// insert template path comment tag
if(config('debug.enabled') && Context::get('logged_info')->is_admin === 'Y')
if(config('debug.enabled') && Rhymix\Framework\Debug::isEnabledForCurrentUser())
{
$sign = PHP_EOL . '<!-- Template %s : ' . $this->web_path . $this->filename . ' -->' . PHP_EOL;
$contents = sprintf($sign, 'start') . $contents . sprintf($sign, 'end');