Fix the replace constraint.