From bd36222eefaa9c4ffd18b27921c428ce744bedd7 Mon Sep 17 00:00:00 2001 From: Robert Haas Date: Mon, 27 Sep 2010 12:28:09 -0400 Subject: [PATCH] Unbreak commitfest_topic_warning code. --- perl-lib/PgCommitFest/Patch.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/perl-lib/PgCommitFest/Patch.pm b/perl-lib/PgCommitFest/Patch.pm index f8c311a..dd3ef69 100644 --- a/perl-lib/PgCommitFest/Patch.pm +++ b/perl-lib/PgCommitFest/Patch.pm @@ -105,6 +105,7 @@ EOM my $commitfest_topic = $r->db->select(<{'commitfest_id'}); SELECT id, name FROM commitfest_topic WHERE commitfest_id = ? ORDER BY name EOM + my $commitfest_topic_warning = ! @$commitfest_topic; unshift @$commitfest_topic, { 'id' => '', 'name' => '(None Selected)' }; $r->control('commitfest_topic')->choice($commitfest_topic); $r->add_control('patch_status', 'select', 'Patch Status', 'required' => 1); @@ -163,7 +164,7 @@ EOM # Display template. $r->render_template('patch_form', { 'id' => $id, 'd' => $d, - 'commitfest_topic_warning' => !@$commitfest_topic, + 'commitfest_topic_warning' => $commitfest_topic_warning, 'new_commitfest' => $cf }); } -- 2.39.5