pylint: enable no-else-return (#5294)

From https://github.com/iterative/dvc/pull/5270#discussion_r559440586
This commit is contained in:
Ruslan Kuprieiev
2021-01-19 22:12:46 +02:00
committed by GitHub
parent d038bca05e
commit 03fc531a5c
11 changed files with 23 additions and 27 deletions
+1 -2
View File
@@ -377,8 +377,7 @@ class GitPythonBackend(BaseGitBackend): # pylint:disable=abstract-method
try:
if follow or self.repo.head.is_detached:
return self.repo.head.commit.hexsha
else:
return f"refs/heads/{self.repo.active_branch}"
return f"refs/heads/{self.repo.active_branch}"
except (GitCommandError, ValueError):
return None
elif name.startswith("refs/heads/"):