Update of /cvsroot/mantisbt/mantisbt/core
In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv5319
Modified Files:
summary_api.php
Log Message:
Do not show private bugs if user has not a proper access level
Index: summary_api.php
===================================================================
RCS file: /cvsroot/mantisbt/mantisbt/core/summary_api.php,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -d -r1.50 -r1.51
--- summary_api.php 31 Jul 2007 22:55:03 -0000 1.50
+++ summary_api.php 1 Aug 2007 07:41:07 -0000 1.51
@@ -297,8 +297,16 @@
$result = db_query( $query );
$t_count = 0;
+ $t_private_bug_threshold = config_get( 'private_bug_threshold'
);
while ( $row = db_fetch_array( $result ) ) {
- if ( $t_count++ == 10 ) break;
+ // Skip private bugs unless user has proper permissions
+ if ( ( VS_PRIVATE == bug_get_field( $row['id'],
'view_state' ) ) &&
+ ( false == access_has_bug_level(
$t_private_bug_threshold, $row['id'] ) ) ) {
+ continue;
+ }
+
+ if ( $t_count++ == 10 ) break;
+
$t_bugid = string_get_bug_view_link( $row['id'] );
$t_summary = $row['summary'];
$t_notescount = $row['count'];
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
|