Skip to content

Commit

Permalink
api: allow rev on local repos
Browse files Browse the repository at this point in the history
  • Loading branch information
Suor committed Jan 19, 2020
1 parent 033ef88 commit 9de0643
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dvc/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ def read(path, repo=None, rev=None, remote=None, mode="r", encoding=None):

@contextmanager
def _make_repo(repo_url, rev=None):
if not repo_url or os.path.exists(repo_url):
if rev is None and (not repo_url or os.path.exists(repo_url)):
yield Repo(repo_url)
else:
with external_repo(url=repo_url, rev=rev) as repo:
Expand Down

0 comments on commit 9de0643

Please sign in to comment.