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

Comments template fix #2095

Merged
merged 1 commit into from Aug 21, 2018
Merged

Comments template fix #2095

merged 1 commit into from Aug 21, 2018

Conversation

mejta
Copy link
Contributor

@mejta mejta commented Aug 21, 2018

Submit a feature request or bug report


What is the current behaviour?

Compiled comments template is included directly and that causes the error with missing $__env variable and that causes that e.g. @foreach cycle doesn't work.

What is the expected or desired behavior?

Comments template is rendered with Blade's render method.


Bug report

Please provide steps to reproduce, including full log output:

  1. add the following code to partials/comments.blade.php
@foreach([1,2,3,4,5] as $i)
  {{ $i }}
@endforeach
  1. an error occures

Please describe your local environment:

WordPress version: 4.9

Where did the bug happen? Development or remote servers?

Everywhere

Is there a related Discourse thread or were any utilized (please link them)?

https://discourse.roots.io/t/why-cant-i-foreach-my-var/12021/3

@mmirus
Copy link
Contributor

mmirus commented Aug 21, 2018

Have confirmed both the bug and that this PR fixes it. Would like review from someone else before merging.

@mmirus mmirus requested a review from QWp6t August 21, 2018 17:21
@retlehs retlehs merged commit 0d4b251 into roots:master Aug 21, 2018
@retlehs
Copy link
Sponsor Member

retlehs commented Aug 21, 2018

thanks y'all!

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

Successfully merging this pull request may close these issues.

None yet

3 participants