cvs: php-bugs-web / bug.php

From: Date: Sun, 19 Jan 2003 01:13:50 +0000
Subject: cvs: php-bugs-web / bug.php
Groups: php.mirrors 
Request: Send a blank email to php-mirrors+get-15164@lists.php.net to get a copy of this message
wez Sat Jan 18 20:13:50 2003 EDT Modified files: /php-bugs-web bug.php Log: Require a comment when marking bugs Bogus, as requested by Derick. Index: php-bugs-web/bug.php diff -u php-bugs-web/bug.php:1.45 php-bugs-web/bug.php:1.46 --- php-bugs-web/bug.php:1.45 Sat Jan 11 19:48:58 2003 +++ php-bugs-web/bug.php Sat Jan 18 20:13:49 2003 @@ -129,6 +129,11 @@ . "\n\n$ncomment"; } } + + if ($in['status'] == 'Bogus' && $bug['status'] != 'Bogus' && strlen(trim($ncomment)) == 0) { + $errors[] = "You must provide a comment when marking a bug 'Bogus'"; + } + if (!$errors && !($errors = incoming_details_are_valid($in))) { $query = "UPDATE bugdb SET sdesc='$in[sdesc]',status='$in[status]', bug_type='$in[bug_type]', assign='$in[assign]', php_version='$in[php_version]', php_os='$in[php_os]', ts2=NOW() WHERE id=$id"; $success = @mysql_query($query); @@ -136,6 +141,7 @@ $query = "INSERT INTO bugdb_comments (bug, email, ts, comment) VALUES ($id,'$user@php.net',NOW(),'$ncomment')"; $success = @mysql_query($query); } + } $from = "$user@php.net"; } @@ -458,4 +464,4 @@ function canvote() { global $thanks, $bug; return ($thanks != 4 && $thanks != 6 && $bug['status'] != "Closed" && $bug['status'] != "Bogus" && $bug['status'] != 'Duplicate'); -} \ No newline at end of file +}

« previous php.mirrors (#15164) next »