forked from loafle/openapi-generator-original
Fix array query param processing
A couple of PHP functions that don't exist in Perl were being called to process array query parameters.
This commit is contained in:
@@ -146,14 +146,13 @@ sub to_path_value {
|
||||
# @return string the serialized object
|
||||
sub to_query_value {
|
||||
my ($self, $object) = @_;
|
||||
if (is_array($object)) {
|
||||
return implode(',', $object);
|
||||
if (ref($object) eq 'ARRAY') {
|
||||
return join(',', @$object);
|
||||
} else {
|
||||
return $self->to_string($object);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
# Take value and turn it into a string suitable for inclusion in
|
||||
# the header. If it's a string, pass through unchanged
|
||||
# If it's a datetime object, format it in ISO8601
|
||||
|
||||
Reference in New Issue
Block a user