Permalink
Browse files

Item5453: value of "0" improperly handled as param to some variables

git-svn-id: http://svn.foswiki.org/trunk@1580 0b4bb1d4-4e5a-0410-9cc4-b2b747904278
  • Loading branch information...
KennethLavrsen KennethLavrsen
KennethLavrsen authored and KennethLavrsen committed Dec 25, 2008
1 parent fb556bf commit 6e22e46cef12deb997bd3a062289648909d8e966
Showing with 2 additions and 1 deletion.
  1. +2 −1 core/lib/Foswiki.pm
View
@@ -3665,7 +3665,8 @@ sub REVARG {
sub ENCODE {
my ( $this, $params ) = @_;
my $type = $params->{type} || 'url';
my $text = $params->{_DEFAULT} || '';
# Value 0 can be valid input so we cannot use simple = || ''
my $text = defined ( $params->{_DEFAULT} ) ? $params->{_DEFAULT} : '';
return _encode( $type, $text );
}

0 comments on commit 6e22e46

Please sign in to comment.