[Rt-commit] r8330 - rt/branches/3.7-EXPERIMENTAL-TUNIS/lib/RT
ruz at bestpractical.com
ruz at bestpractical.com
Tue Jul 31 10:39:57 EDT 2007
Author: ruz
Date: Tue Jul 31 10:39:52 2007
New Revision: 8330
Modified:
rt/branches/3.7-EXPERIMENTAL-TUNIS/lib/RT/CustomField_Overlay.pm
Log:
* add debug info to the log on permission problems
Modified: rt/branches/3.7-EXPERIMENTAL-TUNIS/lib/RT/CustomField_Overlay.pm
==============================================================================
--- rt/branches/3.7-EXPERIMENTAL-TUNIS/lib/RT/CustomField_Overlay.pm (original)
+++ rt/branches/3.7-EXPERIMENTAL-TUNIS/lib/RT/CustomField_Overlay.pm Tue Jul 31 10:39:52 2007
@@ -671,11 +671,15 @@
=cut
sub _Value {
-
my $self = shift;
+ return undef unless $self->id;
# we need to do the rights check
- unless ( $self->id && $self->CurrentUserHasRight('SeeCustomField') ) {
+ unless ( $self->CurrentUserHasRight('SeeCustomField') ) {
+ $RT::Logger->debug(
+ "Permission denied. User #". $self->CurrentUser->id
+ ." has no SeeCustomField right on CF #". $self->id
+ );
return (undef);
}
return $self->__Value( @_ );
More information about the Rt-commit
mailing list