diff options
| author | Simon Wisselink <wisskid@users.noreply.github.com> | 2024-04-29 10:01:40 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-04-29 10:01:40 +0200 |
| commit | 3293a873bdc64bf55e0e53fa5377b3ab8bd9b601 (patch) | |
| tree | c6d4be2b80f0eec23ae8be28e2b6d11d504a3fc0 /src | |
| parent | 8d53d3cbf2a986f392d680349be0fc22661bf16c (diff) | |
| download | smarty-3293a873bdc64bf55e0e53fa5377b3ab8bd9b601.tar.gz smarty-3293a873bdc64bf55e0e53fa5377b3ab8bd9b601.tar.bz2 smarty-3293a873bdc64bf55e0e53fa5377b3ab8bd9b601.zip | |
Remove unused attributes from config_load (#1004)
fixes #993
Diffstat (limited to 'src')
| -rw-r--r-- | src/Compile/Tag/ConfigLoad.php | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/Compile/Tag/ConfigLoad.php b/src/Compile/Tag/ConfigLoad.php index d9e67ec9..8b4cf46d 100644 --- a/src/Compile/Tag/ConfigLoad.php +++ b/src/Compile/Tag/ConfigLoad.php @@ -43,7 +43,7 @@ class ConfigLoad extends Base { * @var array * @see BasePlugin */ - protected $optional_attributes = ['section', 'scope']; + protected $optional_attributes = ['section']; /** * Attribute definition: Overwrites base class. @@ -51,7 +51,7 @@ class ConfigLoad extends Base { * @var array * @see BasePlugin */ - protected $option_flags = ['nocache', 'noscope']; + protected $option_flags = []; /** * Compiles code for the {config_load} tag @@ -66,9 +66,7 @@ class ConfigLoad extends Base { { // check and get attributes $_attr = $this->getAttributes($compiler, $args); - if ($_attr['nocache'] === true) { - $compiler->trigger_template_error('nocache option not allowed', null, true); - } + // save possible attributes $conf_file = $_attr['file']; $section = $_attr['section'] ?? 'null'; |
