diff options
author | Dave Arter <davea@mysociety.org> | 2017-02-07 09:44:34 +0000 |
---|---|---|
committer | Dave Arter <davea@mysociety.org> | 2017-02-07 16:59:45 +0000 |
commit | f68f2bd46607be6cc141034e66af62bd3f64d9dd (patch) | |
tree | 351e8791c53ba48b12b415d2c512e31e193d2df2 /perllib | |
parent | 81b642a59ec389399131880f4850148157787c38 (diff) |
Fix crash on reports with empty bodies_str
Diffstat (limited to 'perllib')
-rw-r--r-- | perllib/FixMyStreet/DB/Result/Comment.pm | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/perllib/FixMyStreet/DB/Result/Comment.pm b/perllib/FixMyStreet/DB/Result/Comment.pm index 26ba89fda..cf1ba444d 100644 --- a/perllib/FixMyStreet/DB/Result/Comment.pm +++ b/perllib/FixMyStreet/DB/Result/Comment.pm @@ -292,7 +292,10 @@ sub meta_line { $update_state = _( 'marked as an internal referral' ) } - if ($c->cobrand->moniker eq 'bromley' || $self->problem->bodies_str eq '2482') { + if ($c->cobrand->moniker eq 'bromley' || ( + $self->problem->bodies_str && + $self->problem->bodies_str eq '2482' + )) { if ($state eq 'not responsible') { $update_state = 'marked as third party responsibility' } |