Use Serializer in LDAP config backend
This commit is contained in:
parent
7d255abdef
commit
2471c79c1a
|
@ -8,8 +8,9 @@ package Lemonldap::NG::Common::Conf::LDAP;
|
|||
use strict;
|
||||
use Net::LDAP;
|
||||
use Lemonldap::NG::Common::Conf::Constants; #inherits
|
||||
use Lemonldap::NG::Common::Conf::Serializer;
|
||||
|
||||
our $VERSION = 0.01;
|
||||
our $VERSION = 0.02;
|
||||
|
||||
BEGIN {
|
||||
*Lemonldap::NG::Common::Conf::ldap = \&ldap;
|
||||
|
@ -122,6 +123,7 @@ sub unlock {
|
|||
|
||||
sub store {
|
||||
my ( $self, $fields ) = @_;
|
||||
$fields = $self->serialize($fields);
|
||||
|
||||
my $confName = "lmConf-" . $fields->{cfgNum};
|
||||
my $confDN = "cn=$confName," . $self->{ldapConfBase};
|
||||
|
@ -172,7 +174,7 @@ sub load {
|
|||
}
|
||||
}
|
||||
$self->ldap->unbind() && delete $self->{ldap};
|
||||
return $f;
|
||||
return $self->unserialize($f);
|
||||
}
|
||||
|
||||
sub delete {
|
||||
|
|
Loading…
Reference in New Issue