[Rt-devel] Queue_Overlay::ValidateName in 3.2.2 vs 3.4.4

Jesse Vincent jesse at bestpractical.com
Thu Dec 1 01:01:17 EST 2005




On Thu, Dec 01, 2005 at 04:41:23PM +1100, Jens Porup wrote:
> 
> I've just upgraded my customized RT 3.2.2 to 3.4.4, and
> there's some sort of conflict with RT::Queue_Overlay::ValidateName.
> 
> After comparing the 3.2.2 version and the 3.4.4 version, it looks
> like Queue_Overlay.pm is pretty much the same, with the following
> change in sub ValidateName:

Are you maybe somewhere calling ValidateName in Class context rather
than object context?


> 
> In 3.2.2:
> 
> 	if ( $tempqueue->Name() ) {
> 
> 
> in 3.4.4:
> 
> 	if ( $tempqueue->Name() && $tempqueue->id != $self->id)  {
> 
> The new code gives me the following error:
> 
> 	error:		Can't use string ("RT::Queue") as a HASH ref while "strict
> 	refs" in use at /usr/share/perl5/DBIx/SearchBuilder/Record.pm line 382.
> 	context:	
> 	...		
> 	378:	*Id = \&id;
> 	379:	
> 	380:	sub id {
> 	381:	my $pkey = $_[0]->_PrimaryKey();
> 	382:	$_[0]->{'values'}->{$pkey};
> 	383:	}
> 	384:	
> 	385:	# }}}
> 	386:	
> 	...		
> 	code stack:		/usr/share/perl5/DBIx/SearchBuilder/Record.pm:382
> 	/opt/rt3/lib/RT/Queue_Overlay.pm:458
> 	/opt/rt3/local/html/Ticket/Elements/ShowSurveyTools:19
> 	/opt/rt3/local/html/Ticket/Elements/ShowSummary:33
> 	/opt/rt3/share/html/Ticket/Display.html:57
> 	/opt/rt3/share/html/autohandler:215
> 
> BUT, reverting to the older code makes it go away.
> 
> What, then, is the significance of the '$tempqueue->id != $self->id)'
> test? What problem was this designed to fix? How can I work around it?
> 
> Thanks,
> 
> Jens
> _______________________________________________
> Rt-devel mailing list
> Rt-devel at lists.bestpractical.com
> http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-devel
> 

-- 


More information about the Rt-devel mailing list