Cleanup

Some small code cleanups