Commit ac5ce7ed authored by Maxime Besson's avatar Maxime Besson
Browse files

Try to get deleted session count from Session module (#2428)

parent 87f27fe0
......@@ -144,8 +144,7 @@ for my $options (@backends) {
next if ( $options->{backend} eq "Apache::Session::Memcached" );
my @t;
if ( $options->{backend}->can('deleteIfLowerThan') ) {
next
if $options->{backend}->deleteIfLowerThan(
my ( $success, $rows ) = $options->{backend}->deleteIfLowerThan(
$options,
{
not => { '_session_kind' => 'Persistent' },
......@@ -158,7 +157,14 @@ for my $options (@backends) {
)
}
}
);
);
if ($success) {
if ($rows) {
$nb_purged += $rows;
}
next;
}
}
# Get all expired sessions
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment