some code clean up, removing unused code