From 9940a27606742f87e9c5f2c5abecd2a9be470b03 Mon Sep 17 00:00:00 2001 From: "Matthew K. Junker" Date: Wed, 13 Oct 2021 08:16:28 -0500 Subject: [PATCH] Interpret 2-digit years as 20xx. --- soccer-time.el | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/soccer-time.el b/soccer-time.el index 98d6a9c..ebcd9d1 100644 --- a/soccer-time.el +++ b/soccer-time.el @@ -27,7 +27,7 @@ ;;; Commentary: ;; Utilities for conversion of time to local time and other nice stuffs -;; +;; ;;; Code: @@ -47,6 +47,8 @@ (day (string-to-number (nth day-position splitted-strings))) (month (string-to-number (nth month-position splitted-strings))) (year (string-to-number (nth year-position splitted-strings)))) + (when (< year 100) + (setq year (+ year 2000))) (list day month year))) (defun soccer-time--get-day-name-from-date (date separator day-position month-position year-position)