From: Aaron Schrab Date: Thu, 12 May 2011 17:43:27 +0000 (-0400) Subject: Avoid warning about exiting sub with next X-Git-Tag: v0.11011~65 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=20530f39ab96c7513b7de6c96f043e4213e3356b;p=dbsrgits%2FSQL-Translator.git Avoid warning about exiting sub with next --- diff --git a/lib/SQL/Translator/Producer/PostgreSQL.pm b/lib/SQL/Translator/Producer/PostgreSQL.pm index 5d8a9aa..025ab73 100644 --- a/lib/SQL/Translator/Producer/PostgreSQL.pm +++ b/lib/SQL/Translator/Producer/PostgreSQL.pm @@ -552,7 +552,7 @@ sub create_index my $type = $index->type || NORMAL; my @fields = $index->fields; - next unless @fields; + return unless @fields; my $def_start = qq[CONSTRAINT ${qf}$name${qf} ]; my $field_names = '(' . join(", ", (map { $_ =~ /\(.*\)/ ? $_ : ($qf . $_ . $qf ) } @fields)) . ')';