[Minor] small error handling change in FileHelper