Additional changes including code cleanup.