fixed dupes bug