Began refactoring again