From: Matt S Trout Date: Thu, 21 Mar 2019 05:18:26 +0000 (+0000) Subject: switch another case to andor expansion X-Git-Tag: v2.000000~3^2~369 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=f8c80416de172bf40c27d22b0860c8b6d57533bf;p=dbsrgits%2FSQL-Abstract.git switch another case to andor expansion --- diff --git a/lib/SQL/Abstract.pm b/lib/SQL/Abstract.pm index b8480b0..96fb8ba 100644 --- a/lib/SQL/Abstract.pm +++ b/lib/SQL/Abstract.pm @@ -753,11 +753,10 @@ sub _expand_expr_hashpair { : $op =~ $self->{not_like_op} ? belch("Supplying an empty arrayref to '@{[ uc $op]}' is deprecated") && $self->sqltrue : puke "operator '$op' applied on an empty array (field '$k')"; } - return +{ -op => [ - $logic =~ /^-(.*)$/, - map $self->_expand_expr({ $k => { $vk => $_ } }), + return $self->_expand_andor($logic => [ + map +{ $k => { $vk => $_ } }, @values - ] }; + ]); } if ( !defined($vv)