From: Marius Gavrilescu Date: Fri, 23 Jan 2015 14:50:15 +0000 (+0200) Subject: Pass contest to /pb/:problem response X-Git-Url: http://git.ieval.ro/?a=commitdiff_plain;h=33ea2780d1269378ffd05309d27ada912eff8408;p=gruntmaster-page.git Pass contest to /pb/:problem response --- diff --git a/lib/Plack/App/Gruntmaster.pm b/lib/Plack/App/Gruntmaster.pm index 4f2d6e1..991159b 100644 --- a/lib/Plack/App/Gruntmaster.pm +++ b/lib/Plack/App/Gruntmaster.pm @@ -183,7 +183,7 @@ sub dispatch_request{ forbid !remote_user; $privacy = 'private'; } - response pb_entry => problem->name, db->problem_entry($_{problem}, $_{contest}, remote_user && remote_user->id); + response pb_entry => problem->name, {%{db->problem_entry($_{problem}, $_{contest}, remote_user && remote_user->id)}, maybe contest => $_{contest}}; }, sub (/sol/:problem) { forbid !problem->is_in_archive;