svn: /web/php-bugs/trunk/www/ bug.php

From: Date: Sun, 25 Jul 2010 19:44:41 +0000
Subject: svn: /web/php-bugs/trunk/www/ bug.php
Groups: php.webmaster 
Request: Send a blank email to php-webmaster+get-8592@lists.php.net to get a copy of this message
felipe Sun, 25 Jul 2010 19:44:41 +0000 Revision: http://svn.php.net/viewvc?view=revision&revision=301546 Log: - Fix block_user_comment initialization Changed paths: U web/php-bugs/trunk/www/bug.php Modified: web/php-bugs/trunk/www/bug.php =================================================================== --- web/php-bugs/trunk/www/bug.php 2010-07-25 19:41:50 UTC (rev 301545) +++ web/php-bugs/trunk/www/bug.php 2010-07-25 19:44:41 UTC (rev 301546) @@ -138,12 +138,16 @@ exit; } -/* Bugs blocked to user comments can only be commented by the team */ -if (isset($_POST['ncomment']) && $bug['block_user_comment'] == 'Y' && !($is_trusted_developer || (isset($logged_in) && $logged_in == 'developer'))) { - response_header('Add comment not allowed'); - display_bug_error("You're not allowed to add comment on bug #{$bug_id}"); - response_footer(); - exit; +if (isset($_POST['ncomment'])) { + /* Bugs blocked to user comments can only be commented by the team */ + if ($bug['block_user_comment'] == 'Y' && !($is_trusted_developer || (isset($logged_in) && $logged_in == 'developer'))) { + response_header('Add comment not allowed'); + display_bug_error("You're not allowed to add comment on bug #{$bug_id}"); + response_footer(); + exit; + } else if (!empty($_POST['in'])) { + $_POST['in']['block_user_comment'] = isset($_POST['in']['block_user_comment']) ? 'S' : 'N'; + } } // Handle any updates, displaying errors if there were any @@ -403,7 +407,6 @@ if ($status == 'Closed' && $_POST['in']['assign'] == '') { $_POST['in']['assign'] = $auth_user->handle; } - $_POST['in']['block_user_comment'] = isset($_POST['in']['block_user_comment']) ? 'S' : 'N'; $dbh->prepare($query . " sdesc = ?,

« previous php.webmaster (#8592) next »