adjust to be more testable