From: Matt S Trout Date: Thu, 18 Apr 2019 02:00:53 +0000 (+0000) Subject: make join_query_parts handle scalars X-Git-Tag: v2.000000~3^2~204 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=6b17028c3bcd90b8b943e457120f48ec88fcd571;p=dbsrgits%2FSQL-Abstract.git make join_query_parts handle scalars --- diff --git a/lib/SQL/Abstract.pm b/lib/SQL/Abstract.pm index 604fc49..ef36eb8 100644 --- a/lib/SQL/Abstract.pm +++ b/lib/SQL/Abstract.pm @@ -1199,8 +1199,11 @@ sub _render_op_multop { sub join_query_parts { my ($self, $join, @parts) = @_; - my @final = map +(ref($_) eq 'HASH' ? [ $self->render_aqt($_) ] : $_), - @parts; + my @final = map +( + ref($_) eq 'HASH' + ? [ $self->render_aqt($_) ] + : ref($_) eq 'ARRAY' ? $_ : [ $_ ]), + @parts; return ( join($join, map $_->[0], @final), (wantarray ? (map @{$_}[1..$#$_], @final) : ()),