small refactoring on bFileAgent