X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/kivitendo-erp.git/blobdiff_plain/722fee3c7224fa0b1222b9f5134e2c19dc021c64..490b0f017ff3f88b192444eda0a46eb84bb1c478:/SL/Dispatcher/AuthHandler/User.pm diff --git a/SL/Dispatcher/AuthHandler/User.pm b/SL/Dispatcher/AuthHandler/User.pm index 5ee543beb..7a8fd1d75 100644 --- a/SL/Dispatcher/AuthHandler/User.pm +++ b/SL/Dispatcher/AuthHandler/User.pm @@ -21,7 +21,7 @@ sub handle { $::locale = Locale->new($::myconfig{countrycode}); $::request->{layout} = SL::Layout::Dispatcher->new(style => $::myconfig{menustyle}); - my $ok = $::auth->get_api_token_cookie ? 1 : 0; + my $ok = $::auth->is_api_token_cookie_valid; $ok ||= $::form->{'{AUTH}login'} && (SL::Auth::OK() == $::auth->authenticate($::myconfig{login}, $::form->{'{AUTH}password'})); $ok ||= !$::form->{'{AUTH}login'} && (SL::Auth::OK() == $::auth->authenticate($::myconfig{login}, undef)); @@ -29,6 +29,7 @@ sub handle { $::auth->create_or_refresh_session; $::auth->delete_session_value('FLASH'); + $::instance_conf->reload->data; return 1; }