Refactor file requires to use common variable.