branch: elpa/hyperdrive commit d13e6ffccb7cda1d343383f5b1b9882f2a9ebd84 Author: Joseph Turner <jos...@ushin.org> Commit: Joseph Turner <jos...@ushin.org>
Revert "Change: (h//url-history) Use h//context-entry by default" With prefix arg or when no current entry exists, h//context-entry prompts using h/read-entry. In this function, we never want to prompt with h/read-entry. This reverts commit 1f8a2def63e45c2d800811425c28bbdb628a39f4. --- hyperdrive-lib.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hyperdrive-lib.el b/hyperdrive-lib.el index c2ff1f70d2..16f096d035 100644 --- a/hyperdrive-lib.el +++ b/hyperdrive-lib.el @@ -1284,7 +1284,8 @@ is passed to `read-string' as its DEFAULT-VALUE argument." (cl-defun h/read-url (&key (prompt "Hyperdrive URL")) "Return URL trimmed of whitespace. Prompts with PROMPT. Defaults to current entry if it exists." - (let ((default (he/url (h//context-entry)))) + (let ((default (and h/current-entry + (he/url h/current-entry)))) (string-trim (read-string (format-prompt prompt default) nil 'h//url-history default))))