refactor router, file interactor