refactor code
re-factored code