aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/App/Controller/Report.pm
diff options
context:
space:
mode:
Diffstat (limited to 'perllib/FixMyStreet/App/Controller/Report.pm')
-rw-r--r--perllib/FixMyStreet/App/Controller/Report.pm11
1 files changed, 11 insertions, 0 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Report.pm b/perllib/FixMyStreet/App/Controller/Report.pm
index 475a29fb5..b3e546c2c 100644
--- a/perllib/FixMyStreet/App/Controller/Report.pm
+++ b/perllib/FixMyStreet/App/Controller/Report.pm
@@ -130,6 +130,17 @@ sub load_problem_or_display_error : Private {
}
$c->stash->{problem} = $problem;
+ if ( $c->user_exists && $c->user->has_permission_to(moderate => $problem->bodies_str) ) {
+ $c->stash->{problem_original} = $problem->find_or_new_related(
+ moderation_original_data => {
+ title => $problem->title,
+ detail => $problem->detail,
+ photo => $problem->photo,
+ anonymous => $problem->anonymous,
+ }
+ );
+ }
+
return 1;
}