aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/Problems.pm
diff options
context:
space:
mode:
Diffstat (limited to 'perllib/Problems.pm')
-rw-r--r--perllib/Problems.pm41
1 files changed, 0 insertions, 41 deletions
diff --git a/perllib/Problems.pm b/perllib/Problems.pm
index 143b5bb9b..a6eb0c519 100644
--- a/perllib/Problems.pm
+++ b/perllib/Problems.pm
@@ -27,20 +27,6 @@ sub current_timestamp {
return "'$current_timestamp'::timestamp";
}
-# Front page statistics
-
-sub recent_fixed {
- my $key = "recent_fixed:$site_key";
- my $result = Memcached::get($key);
- unless ($result) {
- $result = dbh()->selectrow_array("select count(*) from problem
- where state='fixed' and lastupdate>" . current_timestamp() . "-'1 month'::interval
- $site_restriction");
- Memcached::set($key, $result, 3600);
- }
- return $result;
-}
-
sub number_comments {
my $key = "number_comments:$site_key";
my $result = Memcached::get($key);
@@ -58,20 +44,6 @@ sub number_comments {
return $result;
}
-sub recent_new {
- my $interval = shift;
- (my $key = $interval) =~ s/\s+//g;
- $key = "recent_new:$site_key:$key";
- my $result = Memcached::get($key);
- unless ($result) {
- $result = dbh()->selectrow_array("select count(*) from problem
- where state in ('confirmed','fixed') and confirmed>" . current_timestamp() . "-'$interval'::interval
- $site_restriction");
- Memcached::set($key, $result, 3600);
- }
- return $result;
-}
-
# Front page recent lists
sub recent_photos {
@@ -113,19 +85,6 @@ sub recent_photos {
return $out;
}
-sub recent {
- my $key = "recent:$site_key";
- my $result = Memcached::get($key);
- unless ($result) {
- $result = select_all("select id,title from problem
- where state in ('confirmed', 'fixed')
- $site_restriction
- order by confirmed desc limit 5");
- Memcached::set($key, $result, 3600);
- }
- return $result;
-}
-
# Problems around a location
sub around_map {