Clean up some graph code..