mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-26 14:22:01 +00:00
Optimisation: move the importing of Template::Context to runtime.
This commit is contained in:
parent
1998746fe3
commit
ded9adb65d
@ -46,6 +46,10 @@ sub init {
|
|||||||
my($app) = @_;
|
my($app) = @_;
|
||||||
$self->SUPER::init(@_);
|
$self->SUPER::init(@_);
|
||||||
require Template; import Template; # DEPENDENCY
|
require Template; import Template; # DEPENDENCY
|
||||||
|
eval {
|
||||||
|
package PLIF::Service::TemplateToolkit::Context;
|
||||||
|
require Template::Context; import Template::Context; # DEPENDENCY
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
sub expand {
|
sub expand {
|
||||||
@ -77,7 +81,6 @@ sub expand {
|
|||||||
package PLIF::Service::TemplateToolkit::Context;
|
package PLIF::Service::TemplateToolkit::Context;
|
||||||
use strict;
|
use strict;
|
||||||
use vars qw(@ISA);
|
use vars qw(@ISA);
|
||||||
use Template::Context;
|
|
||||||
@ISA = qw(Template::Context);
|
@ISA = qw(Template::Context);
|
||||||
1;
|
1;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user