Refactor Files Controller