Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(3.1.29 -> 3.1.30) Behavior change some new line will not be cutted #268

Closed
MaximilianKresse opened this issue Aug 9, 2016 · 1 comment

Comments

@MaximilianKresse
Copy link

Hi. I found a strange behavior change in 3.1.30:

$template = '
<pre>
foo
{counter start=0 print=false}
{foreach from=$array item=item}
{capture name=itemText}
{$item}
{/capture}
{if $smarty.capture.itemText}
{$smarty.capture.itemText|indent:4}
{/if}
{/foreach}
bar
</pre>
';

$smarty->assign('array', [1, 2, 3, 4, 5]);
echo $smarty->fetch('eval:' . $template);

Output in 3.1.29:

<pre>
foo

    1

    2

    3

    4

    5

bar
</pre>

Output in 3.1.30:

<pre>
foo



    1



    2



    3



    4



    5


bar
</pre>

Is this change intended?

@uwetews
Copy link
Contributor

uwetews commented Sep 7, 2016

This is now fiexed in the master branch

@uwetews uwetews closed this as completed Sep 7, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants