aboutsummaryrefslogtreecommitdiffstats
path: root/bin/problem-creation-graph
diff options
context:
space:
mode:
authorMatthew Somerville <matthew@mysociety.org>2015-09-25 22:35:39 +0100
committerMatthew Somerville <matthew@mysociety.org>2015-12-02 17:41:35 +0000
commit55412b79394ff1b1cabe368aed67fa8f68680ecc (patch)
tree33657093517818b8ba60f156484ec540f9c4af17 /bin/problem-creation-graph
parent0c2a792b154e1b28528db887bbde80b19268b9fe (diff)
Reduce use of FixMyStreet::App.
Command line scripts don't need a full blown app, just database.
Diffstat (limited to 'bin/problem-creation-graph')
-rwxr-xr-xbin/problem-creation-graph4
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/problem-creation-graph b/bin/problem-creation-graph
index 3e46777f4..a8554058a 100755
--- a/bin/problem-creation-graph
+++ b/bin/problem-creation-graph
@@ -20,7 +20,7 @@ BEGIN {
use File::Temp qw(tempfile);
-use FixMyStreet::App;
+use FixMyStreet::DB;
my %config = (
gplot_output => "set terminal png font 'Vera.ttf' 9 size 1200,400",
@@ -43,7 +43,7 @@ sub grab_data {
my ($fh, $filename) = tempfile("fms-creation-rate-graph-data-XXXXXXXXXX", UNLINK => 1);
$sources{$type} = $filename;
- my @entries = FixMyStreet::App->model('DB::Problem')->search(
+ my @entries = FixMyStreet::DB->resultset('Problem')->search(
$selection, {
columns => [
{ 'date' => { date => 'created' } },