X-Git-Url: http://git.ieval.ro/?p=gruntmaster-page.git;a=blobdiff_plain;f=lib%2FGruntmaster%2FPage%2FGeneric.pm;h=35d89adab97874619da159b1a8a24ea5023a6b43;hp=36ca445a98c00c26ee4cae0b3b5190936d56d75d;hb=2e2be9fd67d19611a43a37f39d4bb720f4357cf3;hpb=a46fb222e6ce50102b7c61a95af435afc74f5e33 diff --git a/lib/Gruntmaster/Page/Generic.pm b/lib/Gruntmaster/Page/Generic.pm index 36ca445..35d89ad 100644 --- a/lib/Gruntmaster/Page/Generic.pm +++ b/lib/Gruntmaster/Page/Generic.pm @@ -63,8 +63,7 @@ sub entry { my ($thing, $lang, $env, $id) = @_; my %thing = %$thing; debug $env => "Rsname is $thing{rsname} and id is $id"; - $thing{makers} //= sub { db(shift)->resultset($thing{rsname}) }; - my %params = map {+ rs => $_, $_->get_columns } $thing{makers}->($env)->find($id); + my %params = map {+ rs => $_, $_->get_columns } db($env)->resultset($thing{rsname})->find($id); $thing{mangle}->(local $_ = \%params) if exists $thing{mangle}; wantarray ? %params : \%params }