Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the HTML-FormHandler CPAN distribution.

Report information
The Basics
Id: 71561
Status: resolved
Priority: 0/
Queue: HTML-FormHandler

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

Bug Information
Severity: Important
Broken in: 0.35002
Fixed in: (no value)



Subject: TextArea fields containing 0 (zero) lose their contents
Noticed this in HFH 0.35002.. The TextArea widget contains this code: my $fif = $self->html_filter($result->fif) || ''; which is then used to populate the textarea box. Unfortunately, if the TextArea contains simply the numeral zero (ie. 0) then the above || will fall over to the empty string. The correct way to do this would be to use a defined-or operator, like so, I think.. use 5.10.1; my $fif = $self->html_filter($result->fif) // '';
The other widgets depend on the render filter to return '', so I've changed the TextArea widget to do the same.