diff options
Diffstat (limited to 'app/Controllers/indexController.php')
| -rwxr-xr-x | app/Controllers/indexController.php | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/app/Controllers/indexController.php b/app/Controllers/indexController.php index 84ed992f9..898f2577c 100755 --- a/app/Controllers/indexController.php +++ b/app/Controllers/indexController.php @@ -6,14 +6,12 @@ class FreshRSS_index_Controller extends Minz_ActionController { private $entryDAO; private $feedDAO; private $catDAO; - private $statsDAO; function __construct($router) { parent::__construct($router); $this->entryDAO = new FreshRSS_EntryDAO (); $this->feedDAO = new FreshRSS_FeedDAO (); $this->catDAO = new FreshRSS_CategoryDAO (); - $this->statsDAO = new FreshRSS_StatsDAO (); } public function indexAction () { @@ -202,11 +200,12 @@ class FreshRSS_index_Controller extends Minz_ActionController { } public function statsAction () { + $statsDAO = new FreshRSS_StatsDAO (); Minz_View::appendScript (Minz_Url::display ('/scripts/flotr2.min.js?' . @filemtime(PUBLIC_PATH . '/scripts/flotr2.min.js'))); - $this->view->repartition = $this->statsDAO->calculateEntryRepartition(); - $this->view->count = ($this->statsDAO->calculateEntryCount()); - $this->view->feedByCategory = $this->statsDAO->calculateFeedByCategory(); - $this->view->entryByCategory = $this->statsDAO->calculateEntryByCategory(); + $this->view->repartition = $statsDAO->calculateEntryRepartition(); + $this->view->count = ($statsDAO->calculateEntryCount()); + $this->view->feedByCategory = $statsDAO->calculateFeedByCategory(); + $this->view->entryByCategory = $statsDAO->calculateEntryByCategory(); } public function aboutAction () { |
