=cut
-use Moo 1.000003;
+use Moo;
use SQL::Translator::Utils qw(parse_list_arg ex2err throw carp_ro);
use SQL::Translator::Types qw(schema_obj);
use SQL::Translator::Role::ListAttr;
extends 'SQL::Translator::Schema::Object';
-our $VERSION = '1.59';
+our $VERSION = '1.61';
# Stringify to our name, being careful not to pass any args through so we don't
# accidentally set it to undef. We also have to tweak bool so the object is
}
else {
$self->error('No constraints');
- return wantarray ? () : undef;
+ return;
}
}
}
else {
$self->error('No indices');
- return wantarray ? () : undef;
+ return;
}
}
}
else {
$self->error('No fields');
- return wantarray ? () : undef;
+ return;
}
}
Returns the C<SQL::Translator::Schema::Constraint> object representing
the primary key.
-These are eqivalent:
+These are equivalent:
$table->primary_key('id');
$table->primary_key(['name']);
=head2 options
-Get or set the table's options (e.g., table types for MySQL). Returns
-an array or array reference.
+Get or append to the table's options (e.g., table types for MySQL).
+Returns an array or array reference.
my @options = $table->options;
}
else {
$self->error('No fields');
- return wantarray ? () : undef;
+ return;
}
}