Re: [go-nuts] json -> struct -> html template

2018-02-20 Thread Alex Dvoretskiy
Thanks, Burak! On Tuesday, February 20, 2018 at 4:29:44 PM UTC-8, Burak Serdar wrote: > > On Tue, Feb 20, 2018 at 5:23 PM, Alex Dvoretskiy > > wrote: > > Hello golang-nuts, > > > > https://play.golang.org/p/Lib9EfWcsjG > > > > If you run this code it works fine. But if you remove one "Actor"

Re: [go-nuts] json -> struct -> html template

2018-02-20 Thread Burak Serdar
On Tue, Feb 20, 2018 at 5:23 PM, Alex Dvoretskiy wrote: > Hello golang-nuts, > > https://play.golang.org/p/Lib9EfWcsjG > > If you run this code it works fine. But if you remove one "Actor" key - > template stops executing: "template: movielist:10:14: executing "movielist" > at <.Actor.Name>: can't

[go-nuts] json -> struct -> html template

2018-02-20 Thread Alex Dvoretskiy
Hello golang-nuts, https://play.golang.org/p/Lib9EfWcsjG If you run this code it works fine. But if you remove one "Actor" key - template stops executing: "template: movielist:10:14: executing "movielist" at <.Actor.Name>: can't evaluate field Name in type *main.Actor" Modified version: https: