aboutsummaryrefslogtreecommitdiff
path: root/module/datetime.scm
diff options
context:
space:
mode:
Diffstat (limited to 'module/datetime.scm')
-rw-r--r--module/datetime.scm6
1 files changed, 4 insertions, 2 deletions
diff --git a/module/datetime.scm b/module/datetime.scm
index 1553bad8..de573c2e 100644
--- a/module/datetime.scm
+++ b/module/datetime.scm
@@ -205,7 +205,8 @@
(define-public (date= . args)
(reduce (lambda (a b)
- (and (= (year a) (year b))
+ (and b ; did a previous iteration return false?
+ (= (year a) (year b))
(= (month a) (month b))
(= (day a) (day b))
;; return object
@@ -214,7 +215,8 @@
(define-public (time= . args)
(reduce (lambda (a b)
- (and (= (hour a) (hour b))
+ (and b
+ (= (hour a) (hour b))
(= (minute a) (minute b))
(= (second a) (second b))
a))