From 22d3d70a7285bd0730d301609da05ab09ef640e5 Mon Sep 17 00:00:00 2001 From: Thomas Hochstein Date: Wed, 4 Sep 2013 10:39:40 +0200 Subject: [PATCH] Fix ea91003a99e679caa5bf56915f085a7c4931805b. Commit ea91003a99e679caa5bf56915f085a7c4931805b was broken and did not check for undefined variables. Signed-off-by: Thomas Hochstein --- bin/groupstats.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/groupstats.pl b/bin/groupstats.pl index 7f3a32c..b96a9d6 100755 --- a/bin/groupstats.pl +++ b/bin/groupstats.pl @@ -140,8 +140,8 @@ $OptGroupBy = 'newsgroup' if (!$OptGroupBy and $OptBoundType and $OptBoundType ne 'default'); # default to 'newsgroup' if $OptGroupBy is not set and # just one newsgroup is requested, but more than one month -$OptGroupBy = 'newsgroup' if (!$OptGroupBy and - $OptMonth =~ /:/ and $OptNewsgroups !~ /[:*%]/); +$OptGroupBy = 'newsgroup' if (!$OptGroupBy and $OptMonth and $OptMonth =~ /:/ + and $OptNewsgroups and $OptNewsgroups !~ /[:*%]/); # parse $OptGroupBy to $GroupBy, create ORDER BY clause $SQLOrderClause # if $OptGroupBy is still not set, SQLSortOrder() will default to 'month' my ($GroupBy,$SQLOrderClause) = SQLSortOrder($OptGroupBy, $OptOrderBy);