You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi.
I found that json.cache! was not working when I was using jbuilder template with gon.jbuilder.
I found this error message: undefined method controller' for #<StaffsController:0x007f984fb67440> Did you mean? controller_path
The error comes from this line. https://github.com/rails/jbuilder/blob/master/lib/jbuilder/jbuilder_template.rb#L35
Hello! I'm not sure as I didn't touch jbuilder parsing code for a long time and didn't plan to do so in near future. But if you find out that it is possible and will be compatible with old behavior - we can try to fix it
Hi.
I found that
json.cache!
was not working when I was using jbuilder template withgon.jbuilder
.I found this error message:
undefined method controller' for #<StaffsController:0x007f984fb67440> Did you mean? controller_path
The error comes from this line.
https://github.com/rails/jbuilder/blob/master/lib/jbuilder/jbuilder_template.rb#L35
I think this problem will be fixed by changing the argument
controller
to right one.(
controller
is equal to@context
onJbuilderTemplate
)https://github.com/gazay/gon/blob/master/lib/gon/jbuilder/parser.rb#L69
Is it hard to replace it?
And is there other way to use
json.cache!
when usinggon.jbuilder
?Thanks.
The text was updated successfully, but these errors were encountered: