removed debugging statement
more refactoring