diff options
author | Ulrich Müller <ulm@gentoo.org> | 2023-02-12 20:57:49 +0100 |
---|---|---|
committer | Ulrich Müller <ulm@gentoo.org> | 2023-02-13 07:15:36 +0100 |
commit | cc30422825a5acf460d026bfe912b327b70dedcf (patch) | |
tree | a76e08959b9d65677d1e766de376e9d9edc44a51 /lisp/calendar | |
parent | f2114e8d89feed154a1c523c925ff2fb9fa9ba9a (diff) | |
download | emacs-cc30422825a5acf460d026bfe912b327b70dedcf.tar.gz |
Fix spurious display of eclipses in Calendar
* lisp/calendar/lunar.el (eclipse-check): Don't show an eclipse
unless the phase is new moon or full moon. (bug#61460)
* test/lisp/calendar/lunar-tests.el (lunar-test-eclipse-check)
(lunar-test-phase-list): Update tests.
Diffstat (limited to 'lisp/calendar')
-rw-r--r-- | lisp/calendar/lunar.el | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/calendar/lunar.el b/lisp/calendar/lunar.el index 0db811417af..70681f42c90 100644 --- a/lisp/calendar/lunar.el +++ b/lisp/calendar/lunar.el @@ -161,7 +161,9 @@ remainder mod 4 gives the phase: 0 new moon, 1 first quarter, 2 full moon, (phase-name (cond ((= phase 0) "Solar") ((= phase 2) "Lunar") (t "")))) - (cond ((< moon-lat 2.42600766e-1) + (cond ((string= phase-name "") + "") + ((< moon-lat 2.42600766e-1) (concat "** " phase-name " Eclipse **")) ((< moon-lat 0.37) (concat "** " phase-name " Eclipse possible **")) |