From 94f2881456fa0dcbacec31d7973cc5d9eb9514ce Mon Sep 17 00:00:00 2001 From: Martin Whitaker Date: Sat, 27 Dec 2025 10:08:31 +0000 Subject: Fix inconsistent use of any::sessions() Some callers of any::sessions() expected it to return a list of session names, other callers expected it to return a list of base file names, leading to various bugs in the autologin handling. So provide two new subroutines, session_files(), to provide a map of names to files, and session_names() to return a sorted list of names. Remove sessions() to avoid confusion in future. Fix up the users accordingly. --- perl-install/lang.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'perl-install/lang.pm') diff --git a/perl-install/lang.pm b/perl-install/lang.pm index 5301bd1f3..6767a33d0 100644 --- a/perl-install/lang.pm +++ b/perl-install/lang.pm @@ -970,8 +970,8 @@ sub IM2packages { my ($locale) = @_; if ($locale->{IM}) { require any; - my @sessions = any::sessions(); - $is_plasma = any { /plasma/ } @sessions; + my @sessions = any::session_names(); + $is_plasma = any { /plasma/i } @sessions; my $per_lang = $IM_config{$locale->{IM}}{packages} || {}; my $main_lang = analyse_locale_name($locale->{lang})->{main}; my $packages = $per_lang->{$main_lang} || $per_lang->{generic}; -- cgit v1.2.1