Skip Menu |

This queue is for tickets about the DBIx-Tree-NestedSet CPAN distribution.

Report information
The Basics
Id: 30298
Status: new
Priority: 0/
Queue: DBIx-Tree-NestedSet

People
Owner: Nobody in particular
Requestors: jjarvinen [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 0.16
Fixed in: (no value)



Subject: patch to allow 0 (zero) as params value
example: my $root_id = $tree->add_child_to_right(name => "my_thing", my_other_id => 0); ##-- my_other_id now NULL in DB because _get_params_and_values() is doing: push @values, $params->{$column}||'' .. fixed by checking for defined $params->{$column}
Subject: NestedSet.pm-zero_as_param_value.diff
--- NestedSet.pm.orig 2007-10-27 05:15:09.000000000 -0500 +++ NestedSet.pm 2007-10-27 05:15:30.000000000 -0500 @@ -324,7 +324,7 @@ foreach my $column (keys %$params){ if (not defined $ignore{$column}){ push @params, $column; - push @values, $params->{$column}||'' + push @values, (defined $params->{$column} ? $params->{$column} : ''); } } return (\@params,\@values);