Index: trunk/extensions/ContributionReporting/FundraiserStatistics_body.php |
— | — | @@ -213,8 +213,7 @@ |
214 | 214 | private function query( $type, $start, $end ) { |
215 | 215 | global $wgMemc, $egFundraiserStatisticsMinimum, $egFundraiserStatisticsMaximum; |
216 | 216 | |
217 | | - // Try cache - key exipires once per minute |
218 | | - $key = wfMemcKey( 'fundraiserstatistics', $type, $start, $end, date( 'YmdHi' ) ); |
| 217 | + $key = wfMemcKey( 'fundraiserstatistics', $type, $start, $end ); |
219 | 218 | $cache = $wgMemc->get( $key ); |
220 | 219 | if ( $cache != false && $cache != -1 ) { |
221 | 220 | return $cache; |
— | — | @@ -304,7 +303,8 @@ |
305 | 304 | break; |
306 | 305 | } |
307 | 306 | if ( isset( $result ) ) { |
308 | | - $wgMemc->set( $key, $result ); |
| 307 | + // Cache invalidates once per minute |
| 308 | + $wgMemc->set( $key, $result, 60 ); |
309 | 309 | return $result; |
310 | 310 | } |
311 | 311 | return null; |