-
Notifications
You must be signed in to change notification settings - Fork 14.5k
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
Something seems to be "eating" my locals! #504
Comments
hmm, possibly the new |
The calling routine:
The template: Content Repositories<% if (false && contents) { %>
<% } else { %> -- no content <% } %> Add Domain<%- form.render() %> Foo: <%- foo %> |
(and for test purposes I erased all but the last line of the template) As my gist demonstrates I validated that at the beginning of the view/render routine my local variables were present and by the time the code reached //Attempt Render my local variables were not evident. I have not triangulated the part of http.ServerResponse.prototype.render that "eats" my locals but it is somewhere between those two points. |
hmm, the gist has code from master (2.x), but you use locals: {} ? from 1.x |
seems fine to me, closing for now |
I am passing them in but the ServerResponse.view.render() method eats them before I render!
This is a recent problem - this was not working wrong before the last week or so.
I managed to "patch" the view.render method to re-enable my locals but something in between where I'm saving them and where I'm re-inserting them is destroying the local variable namespace.
My patched version of the view.render method is at https://gist.github.com/781377#comments
The text was updated successfully, but these errors were encountered: