minor refactoring in fn utils