diff options
author | Matthew Somerville <matthew@mysociety.org> | 2019-07-02 14:20:42 +0100 |
---|---|---|
committer | Matthew Somerville <matthew@mysociety.org> | 2019-07-02 14:20:42 +0100 |
commit | 510af28e0bcda19b4f2bf181aaebc05975a7533f (patch) | |
tree | d8e6791fc62c9bb905794a9f24db0aa0b055de78 /perllib/FixMyStreet/DB/ResultSet/Alert.pm | |
parent | 3dd1d1f2cb68b731d23ecea9eb580fe08a190ce8 (diff) | |
parent | 0fee017e4a3d3aac6653f2892cc0950d354f3f91 (diff) |
Merge branch '1084-quote-names'
Diffstat (limited to 'perllib/FixMyStreet/DB/ResultSet/Alert.pm')
-rw-r--r-- | perllib/FixMyStreet/DB/ResultSet/Alert.pm | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/perllib/FixMyStreet/DB/ResultSet/Alert.pm b/perllib/FixMyStreet/DB/ResultSet/Alert.pm index c61053fff..ddf80bc52 100644 --- a/perllib/FixMyStreet/DB/ResultSet/Alert.pm +++ b/perllib/FixMyStreet/DB/ResultSet/Alert.pm @@ -7,11 +7,6 @@ use warnings; sub timeline_created { my ( $rs, $restriction ) = @_; - my $prefetch = - $rs->result_source->storage->sql_maker->quote_char ? - [ qw/alert_type user/ ] : - [ qw/alert_type/ ]; - return $rs->search( { whensubscribed => { '>=', \"current_timestamp-'7 days'::interval" }, @@ -19,7 +14,7 @@ sub timeline_created { %{ $restriction }, }, { - prefetch => $prefetch, + prefetch => [ qw/alert_type user/ ], } ); } |