removed extraneous old code and cleaned up names