More fixes and cleanups