[Rt-commit] r13396 - rt/3.8/trunk/lib/RT
ruz at bestpractical.com
ruz at bestpractical.com
Wed Jun 18 17:01:11 EDT 2008
Author: ruz
Date: Wed Jun 18 17:01:11 2008
New Revision: 13396
Modified:
rt/3.8/trunk/lib/RT/SharedSetting.pm
Log:
* no functional changes, but correctly report a warning
instead of an error
Modified: rt/3.8/trunk/lib/RT/SharedSetting.pm
==============================================================================
--- rt/3.8/trunk/lib/RT/SharedSetting.pm (original)
+++ rt/3.8/trunk/lib/RT/SharedSetting.pm Wed Jun 18 17:01:11 2008
@@ -319,8 +319,13 @@
sub _load_privacy_object {
my ($self, $obj_type, $obj_id) = @_;
- if ( $obj_type eq 'RT::User' && $obj_id == $self->CurrentUser->Id) {
- return $self->CurrentUser->UserObj;
+ if ( $obj_type eq 'RT::User' ) {
+ if ( $obj_id == $self->CurrentUser->Id ) {
+ return $self->CurrentUser->UserObj;
+ } else {
+ $RT::Logger->warning("User #". $self->CurrentUser->Id ." tried to load container user #". $obj_id);
+ return undef;
+ }
}
elsif ($obj_type eq 'RT::Group') {
my $group = RT::Group->new($self->CurrentUser);
More information about the Rt-commit
mailing list