refactoring completed! :D