fix branch initialization