From 1409fb8cfdbac6be6aecb1993077ed6c34bfca0f Mon Sep 17 00:00:00 2001 From: Xavier Guimard Date: Sun, 27 Dec 2015 12:51:49 +0000 Subject: [PATCH] Update conf during startup Closes: #395 --- lemonldap-ng-handler/lib/Lemonldap/NG/Handler/CGI.pm | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lemonldap-ng-handler/lib/Lemonldap/NG/Handler/CGI.pm b/lemonldap-ng-handler/lib/Lemonldap/NG/Handler/CGI.pm index 2625cb157..05649a278 100644 --- a/lemonldap-ng-handler/lib/Lemonldap/NG/Handler/CGI.pm +++ b/lemonldap-ng-handler/lib/Lemonldap/NG/Handler/CGI.pm @@ -17,16 +17,14 @@ sub new { my ( $class, $args ) = @_; my $self = $class->SUPER::new() or $class->abort("Unable to build CGI"); Lemonldap::NG::Handler::SharedConf->init($args); + Lemonldap::NG::Handler::SharedConf->checkConf($self); # Get access control rule my $rule = $self->{protection} || $localConfig->{protection}; $rule =~ s/^rule\s*:?\s*//; return $self if ( $rule eq "none" ); $rule = - $rule eq "authenticate" ? "accept" - : $rule eq "manager" ? "" - : $rule; - + $rule eq "authenticate" ? "accept" : $rule eq "manager" ? "" : $rule; my $request = {}; Lemonldap::NG::Handler::API->newRequest($request); my $res = $self->run($rule);