Mercurial > hg > hg-git
changeset 864:9e0954d9abb3
git_handler: slight style cleanup for previous patch
author | Augie Fackler <raf@durin42.com> |
---|---|
date | Mon, 23 Feb 2015 09:58:01 -0500 (2015-02-23) |
parents | 9036716a1271 |
children | 4d246150d850 |
files | hggit/git_handler.py |
diffstat | 1 files changed, 6 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/hggit/git_handler.py +++ b/hggit/git_handler.py @@ -976,7 +976,12 @@ new_refs = refs.copy() #The remote repo is empty and the local one doesn't have bookmarks/tags - if refs == {} or refs.keys()[0] == 'capabilities^{}': + # + # (older dulwich versions return the proto-level + # capabilities^{} key when the dict should have been + # empty. That check can probably be removed at some point in + # the future.) + if not refs or refs.keys()[0] == 'capabilities^{}': if not exportable: tip = self.repo.lookup('tip') if tip != nullid: