aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/DB
diff options
context:
space:
mode:
authorMatthew Somerville <matthew@mysociety.org>2015-08-17 19:21:45 +0100
committerMatthew Somerville <matthew-github@dracos.co.uk>2015-08-19 15:46:18 +0100
commitf5d6ec933c9fd4d57f9b56fec27f7c746a0706b9 (patch)
tree95f377438cf5166e955698806bfb3291b346ebe1 /perllib/FixMyStreet/DB
parentefa106c52e2668715d17b860a8afa71501691185 (diff)
Use ResultSet/cobrand->problems where appropriate.
Fixes #893.
Diffstat (limited to 'perllib/FixMyStreet/DB')
-rw-r--r--perllib/FixMyStreet/DB/ResultSet/Problem.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/perllib/FixMyStreet/DB/ResultSet/Problem.pm b/perllib/FixMyStreet/DB/ResultSet/Problem.pm
index da80e5b9c..98bd7c68f 100644
--- a/perllib/FixMyStreet/DB/ResultSet/Problem.pm
+++ b/perllib/FixMyStreet/DB/ResultSet/Problem.pm
@@ -236,7 +236,7 @@ sub send_reports {
my $states = [ 'confirmed', 'fixed' ];
$states = [ 'unconfirmed', 'confirmed', 'in progress', 'planned', 'closed' ] if $site eq 'zurich';
- my $unsent = FixMyStreet::App->model("DB::Problem")->search( {
+ my $unsent = $rs->search( {
state => $states,
whensent => undef,
bodies_str => { '!=', undef },
@@ -473,7 +473,7 @@ sub send_reports {
}
}
my $sending_errors = '';
- my $unsent = FixMyStreet::App->model("DB::Problem")->search( {
+ my $unsent = $rs->search( {
state => [ 'confirmed', 'fixed' ],
whensent => undef,
bodies_str => { '!=', undef },