fixed and added some relevent comments