webhook / webhook-cms

The CMS layer for Webhook.com
http://www.webhook.com
MIT License
178 stars 41 forks source link

Can not name relationship field "Type" #232

Open kenzik opened 9 years ago

kenzik commented 9 years ago

Logging this quickly, and will produce a smaller use-case/demo when I get a chance (hopefully this is the right repo for it).

It seems that if I create a relationship field and use the name "Type", the generator dies when rendering that particular template:

Fatal error: Cannot set property _type of # which has only a getter

Renaming that field to anything else that the CMS thinks is valid will work.

LtSquigs commented 9 years ago

Yes this is due to us using _type as a private variable and conflicting with the special relationship field stuff, will talk to mike about a workaround for this (like making a field named type translate to something else)

kenzik commented 9 years ago

Thanks!

Now I don't need to make a small demo of the issue. :-)