diff options
author | Sebastian Thiel <sebastian.thiel@icloud.com> | 2020-04-11 12:57:09 +0800 |
---|---|---|
committer | Sebastian Thiel <sebastian.thiel@icloud.com> | 2020-04-11 12:57:09 +0800 |
commit | bdd4368489345a53bceb40ebd518b961f871b7b3 (patch) | |
tree | 9b11a78a258cc2ef8c5d3f4893c948c518e9721c | |
parent | 2d472327f4873a7a4123f7bdaecd967a86e30446 (diff) | |
download | gitpython-bdd4368489345a53bceb40ebd518b961f871b7b3.tar.gz |
Satisfy flake8 requirement related to #1000
-rw-r--r-- | git/repo/fun.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/git/repo/fun.py b/git/repo/fun.py index e3a7bc57..9d9f8454 100644 --- a/git/repo/fun.py +++ b/git/repo/fun.py @@ -35,7 +35,7 @@ def is_git_dir(d): There is the unlikely danger to throw if we see directories which just look like a worktree dir, but are none.""" if osp.isdir(d): - if (osp.isdir(osp.join(d, 'objects')) or os.environ.has_key('GIT_OBJECT_DIRECTORY')) \ + if (osp.isdir(osp.join(d, 'objects')) or 'GIT_OBJECT_DIRECTORY' in os.environ) \ and osp.isdir(osp.join(d, 'refs')): headref = osp.join(d, 'HEAD') return osp.isfile(headref) or \ |