More code cleanups
More fixes