minor refactor getBean methods