A whole latta code cleanup.