Revert "commitafter: fix ambiguous head error (#4617)"
Created by: keegancsmith
This reverts commit be118dda536291b438478eedf5d3ad686abf0799.
We can revert the commit since we now ensure no repository contains a ref called HEAD. See https://github.com/sourcegraph/sourcegraph/issues/5291
Fixes https://github.com/sourcegraph/sourcegraph/issues/4619