updated comments & small fixes