Update of /cvsroot/mantisbt/mantisbt/core
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3020/core
Modified Files:
access_api.php
Log Message:
fixed per bug access check when threshold is an array and limit_reporters is on
Index: access_api.php
===================================================================
RCS file: /cvsroot/mantisbt/mantisbt/core/access_api.php,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -d -r1.42 -r1.43
--- access_api.php 7 Apr 2005 22:44:54 -0000 1.42
+++ access_api.php 12 May 2005 16:04:09 -0000 1.43
@@ -316,13 +316,13 @@
$p_user_id = auth_get_current_user_id();
}
+ $t_project_id = bug_get_field( $p_bug_id, 'project_id' );
# check limit_Reporter (Issue #4769)
# reporters can view just issues they reported
$t_limit_reporters = config_get( 'limit_reporters' );
- $t_report_bug_threshold = config_get( 'report_bug_threshold' );
- if ( (ON === $t_limit_reporters) &&
- (!bug_is_user_reporter( $p_bug_id, $p_user_id )) &&
- ( current_user_get_access_level() <=
$t_report_bug_threshold ) ) {
+ if ( ( ON === $t_limit_reporters ) &&
+ ( !bug_is_user_reporter( $p_bug_id, $p_user_id ) ) &&
+ ( !access_has_project_level( REPORTER + 1, $t_project_id,
$p_user_id ) ) ) {
return false;
}
@@ -333,8 +333,6 @@
$p_access_level = max( $p_access_level, config_get(
'private_bug_threshold' ) );
}
- $t_project_id = bug_get_field( $p_bug_id, 'project_id' );
-
return access_has_project_level( $p_access_level,
$t_project_id, $p_user_id );
}
-------------------------------------------------------
This SF.Net email is sponsored by Oracle Space Sweepstakes
Want to be the first software developer in space?
Enter now for the Oracle Space Sweepstakes!
http://ads.osdn.com/?ad_id=7393&alloc_id=16281&op=click
|