Loop through all branches