Added better debug information for duplicate error bug