fixed bug in field template creation