mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-06 03:14:27 +02:00
fixed config_load to only load defaults with no section defined
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
===== SVN trunk =====
|
||||
08/03/2011
|
||||
- bugfix loading config file without section should load only defaults
|
||||
03/03/2011
|
||||
- bugfix "smarty" template variable was not recreated when cached templated had expired
|
||||
- bugfix internal rendered_content must be cleared after subtemplate was included
|
||||
|
@@ -272,8 +272,9 @@ class Smarty_Internal_Config {
|
||||
}
|
||||
}
|
||||
// scan sections
|
||||
if(!empty($sections)) {
|
||||
foreach ($_config_vars['sections'] as $this_section => $dummy) {
|
||||
if ($sections == null || in_array($this_section, (array)$sections)) {
|
||||
if (in_array($this_section, (array)$sections)) {
|
||||
foreach ($_config_vars['sections'][$this_section]['vars'] as $variable => $value) {
|
||||
if ($this->smarty->config_overwrite || !isset($scope_ptr->config_vars[$variable])) {
|
||||
$scope_ptr->config_vars[$variable] = $value;
|
||||
@@ -285,4 +286,5 @@ class Smarty_Internal_Config {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
Reference in New Issue
Block a user