summaryrefslogtreecommitdiffstats
path: root/Bugzilla/Util.pm
diff options
context:
space:
mode:
Diffstat (limited to 'Bugzilla/Util.pm')
-rw-r--r--Bugzilla/Util.pm3
1 files changed, 3 insertions, 0 deletions
diff --git a/Bugzilla/Util.pm b/Bugzilla/Util.pm
index 7937d6b80..fd0f8b92e 100644
--- a/Bugzilla/Util.pm
+++ b/Bugzilla/Util.pm
@@ -523,6 +523,9 @@ sub datetime_from {
my ($date, $timezone) = @_;
# In the database, this is the "0" date.
+ use Carp qw(cluck);
+ cluck("undefined date") unless defined $date;
+ return undef unless defined $date;
return undef if $date =~ /^0000/;
my @time;