Remove more unused code; minor code adjustments
More code cleanup