Complete replacement of the old code.