added comments; removed unused method