From 52ff6aa09dc77100b2b5a9bd696d2042d7573e94 Mon Sep 17 00:00:00 2001 From: Frédéric Buclin Date: Fri, 3 Apr 2015 16:36:43 +0200 Subject: Fix bustage due to bug 1007605 (checksetup.pl crashes when installing Bugzilla) --- Bugzilla/Config/BugChange.pm | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'Bugzilla/Config') diff --git a/Bugzilla/Config/BugChange.pm b/Bugzilla/Config/BugChange.pm index 2a225b794..986a74485 100644 --- a/Bugzilla/Config/BugChange.pm +++ b/Bugzilla/Config/BugChange.pm @@ -32,8 +32,13 @@ sub get_param_list { }; my $resolution_field = Bugzilla::Field->new({ name => 'resolution', cache => 1 }); - # The empty resolution is included - it represents "no value" - my @resolutions = map {$_->name} @{ $resolution_field->legal_values }; + my @resolutions = (); + # The 'fielddefs' table is not yet populated when running checksetup.pl + # for the first time. + if ($resolution_field) { + # The empty resolution is included - it represents "no value" + @resolutions = map {$_->name} @{ $resolution_field->legal_values }; + } my @param_list = ( { -- cgit v1.2.3-24-g4f1b