[html-formfu] H:F:M:DBIC condition_from_stash

Ronald J Kimball rkimball at pangeamedia.com
Tue Jan 11 19:54:23 GMT 2011


On Tue, Jan 11, 2011 at 2:27 PM, Gabor HALASZ <halasz.g at freemail.hu> wrote:

> 2011.01.11. 16:39 keltez=E9ssel, Ronald J Kimball =EDrta:
>
>> On Tue, Jan 11, 2011 at 8:21 AM, Gabor HALASZ <halasz.g at freemail.hu
>> <mailto:halasz.g at freemail.hu>> wrote:
>>
>>
>>    I think, simply on wrong place and checks wrong variable, the
>>    correct is:
>>
>>    for my $name ( keys %$from_stash ) {
>>
>>        croak "config value must not be a reference" if ref $name;
>>
>>
>> Checking whether $name is a reference wouldn't make sense.  It's a hash
>> key, so we already know it's a string.
>>
>>  Sure, sorry. Of course, I think:
>
> croak "config value must not be a reference" if ref $form_stash->{$name};
>
>
Aha, yes, that makes sense.  It will use $from_stash->{$name} as a hash key
in $form->stash.  As you said, it's checking the wrong variable.

Ronald
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.scsys.co.uk/pipermail/html-formfu/attachments/20110111/a1=
74926a/attachment.htm


More information about the HTML-FormFu mailing list