Skip to content

Commit

Permalink
swap order of checks to avoid potentially opening a remote connection (
Browse files Browse the repository at this point in the history
…#46)

fixes #45
  • Loading branch information
bricewge authored and wbolster committed Jun 7, 2019
1 parent 468f2fb commit 5633ba2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions direnv.el
Original file line number Diff line number Diff line change
Expand Up @@ -124,9 +124,9 @@ In these modes, direnv will use `default-directory' instead of
(with-current-buffer (window-buffer)
(let ((directory-name (direnv--directory)))
(when (and directory-name
(file-directory-p directory-name)
(not (file-remote-p directory-name))
(not (string-equal direnv--active-directory directory-name))
(not (file-remote-p directory-name)))
(file-directory-p directory-name))
(direnv-update-directory-environment directory-name)))))

(defun direnv--summarise-changes (items)
Expand Down

0 comments on commit 5633ba2

Please # to comment.