Refactoring into more files