mirror of
https://github.com/protesilaos/modus-themes.git
synced 2026-09-10 07:16:30 -04:00
Correct the modus-themes-toggle behaviour to match its doc string
I want to prompt for a theme only if modus-themes-to-toggle is not right. Thanks Morten Kjeldgaard for bringing this matter to my attention in issue 44 in the ef-themes repository (those are built on top of the modus-themes): <https://github.com/protesilaos/ef-themes/issues/44>.
This commit is contained in:
parent
5e1621d638
commit
83501bcd50
|
|
@ -4125,10 +4125,9 @@ Disable other themes per `modus-themes-disable-other-themes'."
|
|||
(interactive)
|
||||
(if-let* ((themes (modus-themes-known-p modus-themes-to-toggle))
|
||||
(one (car themes))
|
||||
(two (cadr themes))
|
||||
(current (modus-themes-get-current-theme)))
|
||||
(modus-themes-load-theme (if (eq current one) two one))
|
||||
(modus-themes-load-theme (modus-themes-select-prompt "No valid theme to toggle; select other"))))
|
||||
(two (cadr themes)))
|
||||
(modus-themes-load-theme (if (eq (modus-themes-get-current-theme) one) two one))
|
||||
(modus-themes-load-theme (modus-themes-select-prompt "No two valid themes to toggle; select other"))))
|
||||
|
||||
;;;;; Rotate through a list of themes
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue