More bugfixes to branch handler