cleaned out the code as per suggestions.