From 88005d674884e3a45f0f6ea251011c4965618ba7 Mon Sep 17 00:00:00 2001 From: Thanos Apollo Date: Wed, 5 Jul 2023 10:52:54 +0300 Subject: fix: remove unused variables --- yeetube.el | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/yeetube.el b/yeetube.el index 5af0873..fe03ab7 100644 --- a/yeetube.el +++ b/yeetube.el @@ -272,7 +272,7 @@ then run this command interactively." "\n~RET~ -> Play Video\n" "\n~d~ -> Download\n" "\n~C-c C-o~ -> Open In Browser\n" - "\n~u~ -> Change search URL (youtube.com or any invidious instance)\n" + "\n~u~ -> Change search URL (youtube.com, any invidious instance or localhost)\n" "\n~C~ -> Change Download Directory\n" "\n~a~ -> Change Download (Audio) Format\n" "\n~q~ -> Quit\n"))) @@ -296,9 +296,9 @@ then run this command interactively." (interactive) (setq yeetube-query-url (read-string "URL: ")) (when (string-prefix-p "localhost" yeetube-query-url) - (setq port (read-string "Port: ")) - (setq yeetube-query-url (concat "http://localhost:" port))) - (unless (string-prefix-p "http://" yeetube-query-url) + (setq yeetube-query-url (concat "http://localhost:" (read-string "Port: ")))) + (unless (or (string-prefix-p "http://" yeetube-query-url) + (string-prefix-p "https://" yeetube-query-url)) (setq yeetube-query-url (concat "https://" yeetube-query-url))) (when (string-suffix-p "/" yeetube-query-url) (setq yeetube-query-url (substring yeetube-query-url 0 -1)))) -- cgit v1.2.3