diff --git a/pkg/function/args.go b/pkg/function/args.go index 0e458f72a7..af4190cf83 100644 --- a/pkg/function/args.go +++ b/pkg/function/args.go @@ -23,7 +23,7 @@ import ( // It will return an error if the argument type does not match the result type func Arg(args map[string]interface{}, argName string, result interface{}) error { if val, ok := args[argName]; ok { - if err := mapstructure.Decode(val, result); err != nil { + if err := mapstructure.WeakDecode(val, result); err != nil { return errors.Wrapf(err, "Failed to decode arg `%s`", argName) } return nil