branches level 2 refactored