minor cleanups + removed unused code