[Rt-devel] Question re. Email.pm code change in RT 3.4.6
Jesse Vincent
jesse at bestpractical.com
Mon Jul 14 16:32:18 EDT 2008
On Jul 14, 2008, at 4:27 PM, Stephen Turner wrote:
> Between RT 3.4.5 and 3.4.6, the way Email.pm looks through the
> MailPlugins list changed from using $_ to using a local variable:
>
> From:
> $_ = "RT::Interface::Email::".$_ unless $_ =~
> /^RT::Interface::Email::/;
> eval "require $_;";
>
> To:
> my $Class = $_;
> $Class = "RT::Interface::Email::" . $Class
> unless $Class =~ /^RT::Interface::Email::/;
> $Class->require or
> do { $RT::Logger->error("Couldn't load $Class: $@");
> next };
>
> Does anyone remember exactly why?
* Killing string eval
* Dealing with weird issues where $_ isn't set properly
* Cleaning up the code.
at least, as i recall
> I ask because we're using the older
> code and we're seeing an intermittent problem in which $_ appears to
> be set to "RT::Interface::Email::" at the eval, causing the require
> to fail, and users' email to be returned with the 'Could not load
> valid user" message. Was this the same reason the code change was
> made? I checked the 3.4.6 Changelog but couldn't see an entry that
> told me the answer.
>
> Thanks,
> Steve
>
>
> Stephen Turner
> Senior Programmer/Analyst - SAIS
> MIT Information Services and Technology (IS&T)
>
> _______________________________________________
> List info: http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-devel
>
More information about the Rt-devel
mailing list