Fix empty retention count display on remotes list page
Fall back to default '30' when RETENTION_COUNT is set to empty string, not just when the key is missing from the config. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -148,7 +148,8 @@ sub handle_list {
|
|||||||
my $conf = GnizaWHM::Config::parse(GnizaWHM::UI::remote_conf_path($name), 'remote');
|
my $conf = GnizaWHM::Config::parse(GnizaWHM::UI::remote_conf_path($name), 'remote');
|
||||||
my $esc_name = GnizaWHM::UI::esc($name);
|
my $esc_name = GnizaWHM::UI::esc($name);
|
||||||
my $type = $conf->{REMOTE_TYPE} // 'ssh';
|
my $type = $conf->{REMOTE_TYPE} // 'ssh';
|
||||||
my $retention = GnizaWHM::UI::esc($conf->{RETENTION_COUNT} // '30');
|
my $retention_raw = $conf->{RETENTION_COUNT} // '';
|
||||||
|
my $retention = GnizaWHM::UI::esc($retention_raw ne '' ? $retention_raw : '30');
|
||||||
|
|
||||||
my ($type_label, $dest);
|
my ($type_label, $dest);
|
||||||
if ($type eq 's3') {
|
if ($type eq 's3') {
|
||||||
|
|||||||
Reference in New Issue
Block a user