Cleanup

I went through and fixed a variety of things that were broken.