cleaned unused code and removed commented out lines