removed unused function and changed comments