diff --git a/Kernel/Modules/AgentTicketQuickClose.pm b/Kernel/Modules/AgentTicketQuickClose.pm index c85a15d9f..f2ab359b5 100644 --- a/Kernel/Modules/AgentTicketQuickClose.pm +++ b/Kernel/Modules/AgentTicketQuickClose.pm @@ -126,6 +126,14 @@ sub _SetState { return if !$State; + if ( $Param{Config}{RequiredLock} ) { + $TicketObject->TicketOwnerSet( + TicketID => $Self->{TicketID}, + UserID => $Self->{UserID}, + NewUserID => $Self->{UserID}, + ); + } + my $Success = $TicketObject->TicketStateSet( State => $State, TicketID => $Self->{TicketID}, diff --git a/Kernel/Output/HTML/Preferences/Password.pm b/Kernel/Output/HTML/Preferences/Password.pm index 65d9b2342..8bb1e982c 100644 --- a/Kernel/Output/HTML/Preferences/Password.pm +++ b/Kernel/Output/HTML/Preferences/Password.pm @@ -214,7 +214,7 @@ sub Run { } # check min 2 char password - if ( $Config->{PasswordMin2Characters} && $Pw !~ /[A-z][A-z]/ ) { + if ( $Config->{PasswordMin2Characters} && $Pw !~ /\w.*\w/ ) { $Self->{Error} = $LanguageObject->Translate('Can\'t update password, it must contain at least 2 letter characters!'); return; } diff --git a/Kernel/System/Stats.pm b/Kernel/System/Stats.pm index 83743efad..1e5dfd912 100644 --- a/Kernel/System/Stats.pm +++ b/Kernel/System/Stats.pm @@ -2864,8 +2864,17 @@ sub _GenerateDynamicStats { # all elements which are shown with multiselectfields if ( $Ref1->{Block} ne 'Time' ) { my %SelectedValues; + SELECTEDVALUE: for my $Ref2 ( @{ $Ref1->{SelectedValues} } ) { + if ( !defined $Ref1->{Values}{$Ref2} ) { + $Kernel::OM->Get('Kernel::System::Log')->Log( + Priority => 'notice', + Message => "Attribute $Ref2 should be used as $Ref1->{Name} in statistic $Param{StatID}, but is not present. Skipping it.", + ); + next SELECTEDVALUE; + } + # Do not translate the values, please see bug#12384 for more information. $SelectedValues{$Ref2} = $Ref1->{Values}{$Ref2}; } diff --git a/scripts/test/Selenium/Output/Preferences/Customer/Password.t b/scripts/test/Selenium/Output/Preferences/Customer/Password.t index 9689ab4cd..e59d37d6a 100644 --- a/scripts/test/Selenium/Output/Preferences/Customer/Password.t +++ b/scripts/test/Selenium/Output/Preferences/Customer/Password.t @@ -72,8 +72,8 @@ $Selenium->RunTest( $Selenium->find_element( "#Update", 'css' )->VerifiedClick(); # check for correct password update preferences message on screen - my $UpdateMessage = "Preferences updated successfully!"; - $Selenium->content_contains( $UpdateMessage, 'Customer preference password - updated' ); + my $UpdateMessage = "Session invalid. Please log in again."; + $Selenium->content_contains( $UpdateMessage, 'Customer preference password - updated and session invalidated.' ); }; } );