21 May
2011
21 May
'11
9:15 p.m.
I see message Dancer::layout has been deprecated since version 1.3050. use 'set layout => "value"' But why was it done? For example: get '/' => sub { # do something my $message = template 'message', $data, {layout=>''}; # sending email with $message or inserting parsed data to DB # do something else template 'index', $data; }; So, in the new way I should read current setting('layout'), save it, set up new layout and restore old layout after if the old-style layout setup will be deprecated. This is ugly! Is there any other ways to do it beautiful? May be it is better to do it optional and not to deprecate this feature? -- Best Regards, Nick Knutov http://knutov.com ICQ: 272873706 Voice: +7-904-84-23-130