Added check for correct branch.