Re: [SMARTY-DEV] config files are always compiled!?
| From: | messju mohr | Date: | Sun, 09 Mar 2003 23:04:47 +0000 |
| Subject: | Re: [SMARTY-DEV] config files are always compiled!? | ||
| References: | 1 | Groups: | php.smarty.dev |
| Request: | Send a blank email to php-smarty-dev+get-930@lists.php.net to get a copy of this message | ||
On Sun, Mar 09, 2003 at 10:57:21PM +0100, Nagger wrote:
> hello...
>
> i've had a look in the function "config_load" in "smarty.class.php"
> and i
> think that config files are always compiled.
> even if they are unchanged.
>
> in line 1305 compiling is set, even if the date-check of the existing
> compiled config file (line 1297) says the file is up-to-date.
> is it a bug?
you mean the lines
if(!empty($_config_vars)) {
$_compile_config = true;
} else {
$_compile_config = false;
}
should read
if(!empty($_config_vars)) {
$_compile_config = false;
} else {
$_compile_config = true;
}
or even better
$_compile_config = empty($_config_vars);
???
yes, i think this is a bug.
> i also think the lines 1333-1335 are unnecessary, because $debug_start_time
> isn't used until line 1355.
>
> bye...
> Nagger