Issue 8238 - templates can create ghost fields

http://d.puremagic.com/issues/show_bug.cgi?id=8238