#241 Refactoring move code to methods