Removing accidental double encoding