More refactoring, YAY!