Workaround for ModPerl/Mouse bug (#1452)
This commit is contained in:
parent
213f674b9e
commit
f4b3e43a2c
|
@ -2,7 +2,6 @@ package Lemonldap::NG::Common::Logger::Log4perl;
|
|||
|
||||
use strict;
|
||||
use Log::Log4perl;
|
||||
use Mouse;
|
||||
|
||||
our $VERSION = '2.0.0';
|
||||
|
||||
|
|
|
@ -8,8 +8,21 @@ package Lemonldap::NG::Common::Session;
|
|||
|
||||
our $VERSION = '2.0.0';
|
||||
|
||||
use Mouse;
|
||||
use Lemonldap::NG::Common::Apache::Session;
|
||||
BEGIN {
|
||||
require Mouse;
|
||||
my $v = $Mouse::VERSION;
|
||||
$v =~ s/^v//;
|
||||
if ( $v =~ /^2\.(?:1|2|3|4)/
|
||||
and $INC{'Lemonldap/NG/Handler/Apache2/Main.pm'} )
|
||||
{
|
||||
require Moose;
|
||||
Moose->import();
|
||||
}
|
||||
else {
|
||||
Mouse->import();
|
||||
}
|
||||
}
|
||||
|
||||
has 'id' => (
|
||||
is => 'rw',
|
||||
|
|
|
@ -4,7 +4,21 @@ use strict;
|
|||
|
||||
use Safe;
|
||||
use Lemonldap::NG::Common::Safelib; #link protected safe Safe object
|
||||
use Mouse;
|
||||
|
||||
BEGIN {
|
||||
require Mouse;
|
||||
my $v = $Mouse::VERSION;
|
||||
$v =~ s/^v//;
|
||||
if ( $v =~ /^2\.(?:1|2|3|4)/
|
||||
and $INC{'Lemonldap/NG/Handler/Apache2/Main.pm'} )
|
||||
{
|
||||
require Moose;
|
||||
Moose->import();
|
||||
}
|
||||
else {
|
||||
Mouse->import();
|
||||
}
|
||||
}
|
||||
|
||||
has customFunctions => ( is => 'rw', isa => 'Maybe[Str]' );
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user