Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

smarty_internal_compile_section.php v3.1.30

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Bugs
View previous topic :: View next topic  
Author Message
mixio
Smarty n00b


Joined: 26 Jan 2017
Posts: 1
Location: Paris, France

PostPosted: Thu Jan 26, 2017 8:36 am    Post subject: smarty_internal_compile_section.php v3.1.30 Reply with quote

Section loops weren't displayed. This patch seems to correct the problem.

---
libs/sysplugins/smarty_internal_compile_section.php | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/libs/sysplugins/smarty_internal_compile_section.php b/libs/sysplugins/smarty_internal_compile_section.php
index c3701fc6..cead6d99 100644
--- a/libs/sysplugins/smarty_internal_compile_section.php
+++ b/libs/sysplugins/smarty_internal_compile_section.php
@@ -143,7 +143,9 @@ class Smarty_Internal_Compile_Section extends Smarty_Internal_Compile_Private_Fo
if (isset($namedAttr[ 'loop' ])) {
$initNamedProperty[ 'loop' ] = "'loop' => {$v}";
if ($t == 1) {
- $v = "{$sectionVar}->value['loop']";
+ //$v = "{$sectionVar}->value['loop']";
+ $initLocal[ 'loop' ] = $v;
+ $v = "{$local}loop";
}
} elseif ($t == 1) {
$initLocal[ 'loop' ] = $v;
--
2.11.0
Back to top
View user's profile Send private message
AnrDaemon
Administrator


Joined: 03 Dec 2012
Posts: 1785

PostPosted: Fri Jan 27, 2017 8:40 am    Post subject: Reply with quote

Please provide tests demonstating your issue and proving that there's no regressions after your changes.
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Bugs All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP