From: Moritz Bunkus Date: Mon, 9 Nov 2020 09:59:06 +0000 (+0100) Subject: SL::DB::Employee: Warnung vermeiden X-Git-Tag: kivitendo-mebil_0.1-0~9^2~661 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=fe18b19ff491efb6768b5ddd56f9eb1c6b1f4467;p=kivitendo-erp.git SL::DB::Employee: Warnung vermeiden --- diff --git a/SL/DB/Manager/Employee.pm b/SL/DB/Manager/Employee.pm index f9642ab7b..400843bba 100644 --- a/SL/DB/Manager/Employee.pm +++ b/SL/DB/Manager/Employee.pm @@ -31,6 +31,8 @@ sub update_entries_for_authorized_users { my %employees_by_login = map { ($_->login => $_) } @{ $class->get_all }; require SL::DB::AuthClient; + no warnings 'once'; + foreach my $user (@{ SL::DB::AuthClient->new(id => $::auth->client->{id})->load->users || [] }) { my $user_config = $user->config_values; my $employee = $employees_by_login{$user->login} || SL::DB::Employee->new(login => $user->login);