[PATCH 4/4] B&M: refactor branch-from-image