Fixed a bug with field duplication