minor refactoring with new extension methods for config