handle the values 0 and empty string in getOriginalValue

This commit is contained in:
Colin Kuskie 2008-08-15 18:38:12 +00:00
parent d2413148a8
commit b143376cf0

View file

@ -419,7 +419,9 @@ Returns the either the "value" or "defaultValue" passed in to the object in that
sub getOriginalValue {
my $self = shift;
return $self->get("value") || $self->getDefaultValue();
my $value = $self->get('value');
return $value if (defined $value); ##Handle returning 0 and empty string
return $self->getDefaultValue;
}
#-------------------------------------------------------------------