From: Justin Hunter Date: Tue, 9 Feb 2010 06:22:31 +0000 (-0800) Subject: coerce Str to ArrayRef X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=a0a9baf513cf49a34a4a65b9a48a95cde673422d;p=dbsrgits%2FSQL-Translator-2.0-ish.git coerce Str to ArrayRef --- diff --git a/lib/SQL/Translator/Object.pm b/lib/SQL/Translator/Object.pm index e6970ec..3091d79 100644 --- a/lib/SQL/Translator/Object.pm +++ b/lib/SQL/Translator/Object.pm @@ -7,6 +7,7 @@ class SQL::Translator::Object with SQL::Translator::Object::Compat { has '_comments' => ( traits => ['Array'], isa => ArrayRef, + coerce => 1, handles => { _comments => 'elements', add_comment => 'push', @@ -18,6 +19,7 @@ class SQL::Translator::Object with SQL::Translator::Object::Compat { has '_options' => ( traits => ['Array'], isa => ArrayRef, + coerce => 1, handles => { _options => 'elements', add_option => 'push',