Item331: Func broken when called via TWikiCompatibilityPlugin
Priority: Urgent
Current State: Closed
Released In:
Target Release:
Applies To: Engine
Component:
Branches:
For instance
registerRESTHandler()
has got a
my $plugin = caller;
in it ... which returns
Func
as the caller is the Func bridge of the
TWikiCompatibilityPlugin for
old TWiki plugins. The other Func methods might be broken as well when they are called via
TWikiCompatibilityPlugin and have a
caller
in it.
Something like
$plugin = caller(1) if $plugin eq 'TWiki::Func';
would fix it, but I can imagine that this all gets terribly inefficient.
Most probably the Func bridge needs to be redesigned.
--
MichaelDaum - 28 Nov 2008
Well, "redesigned" might be a bit of overkill. It's simple enough to equivalence the few methods that use
caller
.
Re-opening the bug to make the alias alias only the function, as per:
http://perldoc.perl.org/perlmod.html
Note for self: why not re-write all other functions too, aliases are quicker than function calls, and we're not using them anyway.
--
OlivierRaginel - 05 Dec 2008