From: Paul Hänsch Date: Fri, 6 Sep 2024 11:42:35 +0000 (+0200) Subject: bugfix: initialize variables when declaring local X-Git-Url: https://git.plutz.net/?a=commitdiff_plain;h=db5247b4e9d102ae11ad48231b1136f280e33d31;p=shellwiki bugfix: initialize variables when declaring local --- diff --git a/macros/calendar b/macros/calendar index e680cf0..b05c264 100755 --- a/macros/calendar +++ b/macros/calendar @@ -239,7 +239,7 @@ events="$( cal_list() { # Print list view for upcoming events - local lday='' events sdate=$(date -ud "${DY}-${DM}-${DD}" +%s) + local lday='' events="$events" sdate=$(date -ud "${DY}-${DM}-${DD}" +%s) events="$( printf %s\\n "$events" \ @@ -263,7 +263,7 @@ cal_list() { } cal_month() { - local ws="$ws" events calmonth + local ws="$ws" events="$events" calmonth local iday idow mname dcnt dow dcal start end title link n calmonth="$(GET calmonth || printf %i "$((DY * 12 + DM))")"