refactoring: file handler made void