[html-formfu] Can't modify non-lvalue

Carl Franks fireartist at gmail.com
Tue Sep 23 08:50:08 BST 2008


2008/9/23 Tobias Henoeckl <hoeni-formfu at sisyphus.de>:
> Hi,
>
> when using my form I get an error:
>
> Caught exception in TTT::Controller::Project->edit "Can't modify
> non-lvalue subroutine call at
> /usr/local/lib/perl5/site_perl/5.8.8/HTML/FormFu/Element.pm line 84.
>
>
> ---- 8<---- SCHNIPP ------------------------------------------------
> $self->model_config ||= {};
> my $conf = $self->model_config;
> ...
> ---- 8<---- SCHNAPP ------------------------------------------------
>
>
> Shouldn't it be rather like this?
> ---- 8<---- SCHNIPP ------------------------------------------------
> $self->model_config;
> my $conf = $self->model_config || {};
> ...
> ---- 8<---- SCHNAPP ------------------------------------------------
>
> Or did I miss the point?

Yup - it was a bug - it's fixed in svn now.

Take notice of the warnings issued by that db() method, though - it is
deprecated, and *will* be removed.

Cheers,
Carl



More information about the HTML-FormFu mailing list