aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/DB
diff options
context:
space:
mode:
authorMatthew Somerville <matthew-github@dracos.co.uk>2016-11-25 17:57:01 +0000
committerMatthew Somerville <matthew-github@dracos.co.uk>2016-11-29 18:14:22 +0000
commit6989e6d72e7e13f27c42fd4587294191e600a1a5 (patch)
tree7d88c9686f7fad0a2bf25ec07d4c068f03f5e028 /perllib/FixMyStreet/DB
parent82d08bb2a2b9f5c5ad594e65ad218e25050d62d7 (diff)
Always return arrayref from bodies_str_ids.
Prevents potential odd-element hash in e.g. response_priorities.
Diffstat (limited to 'perllib/FixMyStreet/DB')
-rw-r--r--perllib/FixMyStreet/DB/Result/Problem.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/perllib/FixMyStreet/DB/Result/Problem.pm b/perllib/FixMyStreet/DB/Result/Problem.pm
index f421394fa..ab6f20050 100644
--- a/perllib/FixMyStreet/DB/Result/Problem.pm
+++ b/perllib/FixMyStreet/DB/Result/Problem.pm
@@ -475,7 +475,7 @@ sub confirm {
sub bodies_str_ids {
my $self = shift;
- return unless $self->bodies_str;
+ return [] unless $self->bodies_str;
my @bodies = split( /,/, $self->bodies_str );
return \@bodies;
}