cvs: smarty /libs Smarty_Compiler.class.php
"Messju Mohr" <[email protected]>
| Newsgroups | gmane.comp.php.cvs.smarty |
|---|---|
| Message-ID | <cvsmessju1056387705@cvsserver> |
messju Mon Jun 23 13:01:45 2003 EDT
Modified files:
/smarty/libs Smarty_Compiler.class.php
Log:
removed warning when compiling empty template
Index: smarty/libs/Smarty_Compiler.class.php
diff -u smarty/libs/Smarty_Compiler.class.php:1.250 smarty/libs/Smarty_Compiler.class.php:1.251
--- smarty/libs/Smarty_Compiler.class.php:1.250 Sat Jun 21 08:20:17 2003
+++ smarty/libs/Smarty_Compiler.class.php Mon Jun 23 13:01:45 2003
@@ -39,7 +39,7 @@
* @package Smarty
*/
-/* $Id: Smarty_Compiler.class.php,v 1.250 2003/06/21 12:20:17 messju Exp $ */
+/* $Id: Smarty_Compiler.class.php,v 1.251 2003/06/23 17:01:45 messju Exp $ */
/**
* Template compiling class
* @package Smarty
@@ -329,7 +329,7 @@
$compiled_content .= $text_blocks[$i];
// remove \n from the end of the file, if any
- if ($compiled_content{strlen($compiled_content) - 1} == "\n" ) {
+ if (($_len=strlen($compiled_content)) && ($compiled_content{$_len - 1} == "\n" )) {
$compiled_content = substr($compiled_content, 0, -1);
}
--
Smarty CVS Mailing List (http://cvs.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php