Fixed annoying error message when in detached HEAD