[Jifty-commit] jifty-dbi branch, master, updated. 0.60-6-g2699ce0

Jifty commits jifty-commit at lists.jifty.org
Mon May 3 03:47:26 EDT 2010


The branch, master has been updated
       via  2699ce046db862ce242fc8fa4ed68695df610178 (commit)
      from  16dc121b6b5f13de220f3d0e18a7ac0608a11c51 (commit)

Summary of changes:
 lib/Jifty/DBI/Filter/Boolean.pm |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

- Log -----------------------------------------------------------------
commit 2699ce046db862ce242fc8fa4ed68695df610178
Author: Shawn M Moore <sartak at bestpractical.com>
Date:   Mon May 3 15:47:31 2010 +0800

    Avoid undef warning

diff --git a/lib/Jifty/DBI/Filter/Boolean.pm b/lib/Jifty/DBI/Filter/Boolean.pm
index b8ecfdd..c82ef1d 100644
--- a/lib/Jifty/DBI/Filter/Boolean.pm
+++ b/lib/Jifty/DBI/Filter/Boolean.pm
@@ -77,8 +77,8 @@ sub encode {
     my $self = shift;
     my $value_ref = $self->value_ref;
 
-    return unless defined $$value_ref or $self->column->mandatory;
-    return if uc $$value_ref eq "NULL" and not $self->column->mandatory;
+    return unless defined($$value_ref) or $self->column->mandatory;
+    return if uc($$value_ref||'') eq "NULL" and not $self->column->mandatory;
 
     if ($self->_is_true($$value_ref)) {
         $$value_ref = $self->handle->canonical_true;

-----------------------------------------------------------------------


More information about the Jifty-commit mailing list