Allow arrays in args

Just check that args is a Hash without checking the value types.

Fixes: https://github.com/basecamp/kamal/issues/863
This commit is contained in:
Donal McBreen
2024-06-25 14:11:08 +01:00
parent ff03891d47
commit b63982c3a7
3 changed files with 8 additions and 3 deletions

View File

@@ -31,9 +31,9 @@ class Kamal::Configuration::Validator
validate_array_of! value, example_value.first.class
elsif example_value.is_a?(Hash)
case key.to_s
when "options"
when "options", "args"
validate_type! value, Hash
when "args", "labels"
when "labels"
validate_hash_of! value, example_value.first[1].class
else
validate_against_example! value, example_value