From: Matt S Trout Date: Sat, 24 Aug 2019 04:13:04 +0000 (+0000) Subject: format works X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=7c4d227d9872eb148fc76f3b1f95c30db17ae89c;p=scpubgit%2FQ-Branch.git format works --- diff --git a/lib/SQL/Abstract/Formatter.pm b/lib/SQL/Abstract/Formatter.pm index 829b110..1011de8 100644 --- a/lib/SQL/Abstract/Formatter.pm +++ b/lib/SQL/Abstract/Formatter.pm @@ -17,7 +17,7 @@ sub format { my $sql = $self->_join($join, @parts); return $sql unless length($sql) > $self->max_width; local $self->{max_width} = $self->{max_width} - length($self->indent_by); - return join("\n", map $self->format(@$_), @parts); + return join("\n", map ref() ? $self->format(@$_) : $_, @parts); } 1;