Add explicit return
s
This commit is contained in:
parent
ee7fe2c7b4
commit
c5c074903d
44 changed files with 191 additions and 11 deletions
|
@ -146,6 +146,8 @@ sub sqlt_deploy_hook {
|
|||
else {
|
||||
$pending_field->{default_value} = \"false";
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
sub to_bool {
|
||||
|
|
|
@ -103,6 +103,8 @@ sub sqlt_deploy_hook {
|
|||
else {
|
||||
$pending_field->{default_value} = \"false";
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
1;
|
||||
|
|
|
@ -84,6 +84,12 @@ __PACKAGE__->has_many(
|
|||
{ cascade_copy => 0, cascade_delete => 0 },
|
||||
);
|
||||
|
||||
__PACKAGE__->filter_column(
|
||||
is_admin => {
|
||||
filter_to_storage => 'to_bool',
|
||||
}
|
||||
);
|
||||
|
||||
sub sqlt_deploy_hook {
|
||||
my ( $source_instance, $sqlt_table ) = @_;
|
||||
my $pending_field = $sqlt_table->get_field('is_admin');
|
||||
|
@ -93,14 +99,10 @@ sub sqlt_deploy_hook {
|
|||
else {
|
||||
$pending_field->{default_value} = \"false";
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
__PACKAGE__->filter_column(
|
||||
is_admin => {
|
||||
filter_to_storage => 'to_bool',
|
||||
}
|
||||
);
|
||||
|
||||
sub to_bool {
|
||||
my ( $self, $val ) = @_;
|
||||
my $driver_name =
|
||||
|
|
Reference in a new issue