Mostly code cleanup and getting back on track