start splitting up to make more testable