Merge branch 'ignore-duplicate-template-keys' into prepare-2.3.0

This commit is contained in:
Christoph Klaffl 2025-06-05 22:40:11 +02:00
commit 1915ea29a2
No known key found for this signature in database
GPG Key ID: 8FC1D76EED4970D2
1 changed files with 6 additions and 0 deletions

6
sanoid
View File

@ -1008,6 +1008,12 @@ sub init {
}
if ($args{'debug'}) { print "DEBUG: overriding $key on $section with value from user-defined template $template.\n"; }
$config{$section}{$key} = $ini{$template}{$key};
my $value = $config{$section}{$key};
if (ref($value) eq 'ARRAY') {
# handle duplicates silently (warning was already printed above)
$config{$section}{$key} = $value->[0];
}
}
}
}