Major cleanup of Disco-related code