diff options
| author | Damien Cassou | 2018-03-26 06:28:17 +0200 |
|---|---|---|
| committer | Nicolas Petton | 2018-06-05 15:52:02 +0200 |
| commit | 03c50fc7aecab0b42f9f80600d7cbc4c53bae54a (patch) | |
| tree | fed71cb777368ba15653bb27e48b1b27721ee5b1 | |
| parent | a6cbdd4e6f75d40977719892af53fee5488a2c0e (diff) | |
| download | emacs-03c50fc7aecab0b42f9f80600d7cbc4c53bae54a.tar.gz emacs-03c50fc7aecab0b42f9f80600d7cbc4c53bae54a.zip | |
Make sure auth-source-pass is compatible with Emacs 25
* lisp/auth-source-pass.el: Use `advice-add' for Emacs 25 users as
`auth-source-backend-parser-functions' does not exist there.
| -rw-r--r-- | lisp/auth-source-pass.el | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/auth-source-pass.el b/lisp/auth-source-pass.el index 1193d67954b..d5c61398143 100644 --- a/lisp/auth-source-pass.el +++ b/lisp/auth-source-pass.el | |||
| @@ -92,7 +92,9 @@ See `auth-source-search' for details on SPEC." | |||
| 92 | (when (eq entry 'password-store) | 92 | (when (eq entry 'password-store) |
| 93 | (auth-source-backend-parse-parameters entry auth-source-pass-backend))) | 93 | (auth-source-backend-parse-parameters entry auth-source-pass-backend))) |
| 94 | 94 | ||
| 95 | (add-hook 'auth-source-backend-parser-functions #'auth-source-pass-backend-parse) | 95 | (if (boundp 'auth-source-backend-parser-functions) |
| 96 | (add-hook 'auth-source-backend-parser-functions #'auth-source-pass-backend-parse) | ||
| 97 | (advice-add 'auth-source-backend-parse :before-until #'auth-source-pass-backend-parse)) | ||
| 96 | 98 | ||
| 97 | 99 | ||
| 98 | (defun auth-source-pass-get (key entry) | 100 | (defun auth-source-pass-get (key entry) |