I don't like this system of keeping `duplicatedAttribute` as a member variable. See the constructor for potential solutions