rename_ref(): handle the case when the reflog of a ref does not exist