diff options
32 files changed, 60 insertions, 92 deletions
diff --git a/core/API/Proxy.php b/core/API/Proxy.php index accdb1feaa..353ecc185b 100644 --- a/core/API/Proxy.php +++ b/core/API/Proxy.php @@ -53,9 +53,8 @@ class Piwik_API_Proxy static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/core/DataTable/Manager.php b/core/DataTable/Manager.php index 6120482635..8f586eb72a 100644 --- a/core/DataTable/Manager.php +++ b/core/DataTable/Manager.php @@ -29,9 +29,8 @@ class Piwik_DataTable_Manager static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/core/Db/Schema.php b/core/Db/Schema.php index 22c0dd5806..38b154872d 100644 --- a/core/Db/Schema.php +++ b/core/Db/Schema.php @@ -33,8 +33,7 @@ class Piwik_Db_Schema { if (self::$instance === null) { - $c = __CLASS__; - self::$instance = new $c(); + self::$instance = new self; } return self::$instance; } diff --git a/core/FrontController.php b/core/FrontController.php index 94ae313c34..9645728716 100644 --- a/core/FrontController.php +++ b/core/FrontController.php @@ -48,9 +48,8 @@ class Piwik_FrontController static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/core/Menu/Admin.php b/core/Menu/Admin.php index d06db2d1cd..3fc545400b 100644 --- a/core/Menu/Admin.php +++ b/core/Menu/Admin.php @@ -22,9 +22,8 @@ class Piwik_Menu_Admin extends Piwik_Menu_Abstract static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/core/Menu/Main.php b/core/Menu/Main.php index c2260ae7ec..bffb4bb6dc 100644 --- a/core/Menu/Main.php +++ b/core/Menu/Main.php @@ -23,9 +23,8 @@ class Piwik_Menu_Main extends Piwik_Menu_Abstract static public function getInstance() { if (self::$instance == null) - { - $c = get_class(); - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/core/Menu/Top.php b/core/Menu/Top.php index 2a023d77ff..59cc123b1b 100644 --- a/core/Menu/Top.php +++ b/core/Menu/Top.php @@ -22,9 +22,8 @@ class Piwik_Menu_Top extends Piwik_Menu_Abstract static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/core/Option.php b/core/Option.php index 983083e7b1..5f970259dd 100644 --- a/core/Option.php +++ b/core/Option.php @@ -31,9 +31,8 @@ class Piwik_Option static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/core/PluginsManager.php b/core/PluginsManager.php index 13ade39e2c..4c029c785e 100644 --- a/core/PluginsManager.php +++ b/core/PluginsManager.php @@ -65,9 +65,8 @@ class Piwik_PluginsManager static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/core/Tracker/Config.php b/core/Tracker/Config.php index 5927655a09..a8ecd08fb4 100644 --- a/core/Tracker/Config.php +++ b/core/Tracker/Config.php @@ -42,9 +42,8 @@ class Piwik_Tracker_Config static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/core/Translate.php b/core/Translate.php index 4a722f41d8..59561f218e 100644 --- a/core/Translate.php +++ b/core/Translate.php @@ -24,9 +24,8 @@ class Piwik_Translate static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/API/API.php b/plugins/API/API.php index 27f9d7f0e6..6eed4fe8e6 100644 --- a/plugins/API/API.php +++ b/plugins/API/API.php @@ -43,7 +43,6 @@ class Piwik_API extends Piwik_Plugin { $cssFiles[] = "plugins/API/css/styles.css"; } - } @@ -62,8 +61,7 @@ class Piwik_API_API { if (self::$instance == null) { - $c = __CLASS__; - self::$instance = new $c(); + self::$instance = new self; } return self::$instance; } diff --git a/plugins/Actions/API.php b/plugins/Actions/API.php index 955350b5d9..4f3b0dda75 100644 --- a/plugins/Actions/API.php +++ b/plugins/Actions/API.php @@ -23,8 +23,7 @@ class Piwik_Actions_API { if (self::$instance == null) { - $c = __CLASS__; - self::$instance = new $c(); + self::$instance = new self; } return self::$instance; } diff --git a/plugins/CoreAdminHome/API.php b/plugins/CoreAdminHome/API.php index da04fc5e63..1357ce0d79 100644 --- a/plugins/CoreAdminHome/API.php +++ b/plugins/CoreAdminHome/API.php @@ -21,8 +21,7 @@ class Piwik_CoreAdminHome_API { if (self::$instance == null) { - $c = __CLASS__; - self::$instance = new $c(); + self::$instance = new self; } return self::$instance; } diff --git a/plugins/DBStats/API.php b/plugins/DBStats/API.php index 59eca32f6d..1b39ec30c4 100644 --- a/plugins/DBStats/API.php +++ b/plugins/DBStats/API.php @@ -20,9 +20,8 @@ class Piwik_DBStats_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/ExampleAPI/API.php b/plugins/ExampleAPI/API.php index 085d5355af..34e663958e 100644 --- a/plugins/ExampleAPI/API.php +++ b/plugins/ExampleAPI/API.php @@ -45,8 +45,7 @@ class Piwik_ExampleAPI_API { if (self::$instance == null) { - $c = __CLASS__; - self::$instance = new $c(); + self::$instance = new self; } return self::$instance; } diff --git a/plugins/ExampleUI/API.php b/plugins/ExampleUI/API.php index 08c5888144..02031a3dc8 100644 --- a/plugins/ExampleUI/API.php +++ b/plugins/ExampleUI/API.php @@ -19,9 +19,8 @@ class Piwik_ExampleUI_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/Goals/API.php b/plugins/Goals/API.php index e2193cb00d..56a66fcf93 100644 --- a/plugins/Goals/API.php +++ b/plugins/Goals/API.php @@ -23,9 +23,8 @@ class Piwik_Goals_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/LanguagesManager/API.php b/plugins/LanguagesManager/API.php index 6eec3ba630..9ae15e9bb6 100644 --- a/plugins/LanguagesManager/API.php +++ b/plugins/LanguagesManager/API.php @@ -21,9 +21,8 @@ class Piwik_LanguagesManager_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/Live/API.php b/plugins/Live/API.php index 7bf4e7b5d7..400882ef60 100644 --- a/plugins/Live/API.php +++ b/plugins/Live/API.php @@ -28,8 +28,7 @@ class Piwik_Live_API { if (self::$instance == null) { - $c = __CLASS__; - self::$instance = new $c(); + self::$instance = new self; } return self::$instance; } @@ -227,8 +226,9 @@ class Piwik_Live_API array_push( $where, Piwik_Common::prefixTable('log_visit') . ".visit_first_action_time BETWEEN ? AND ?"); array_push( $whereBind, - $processedPeriod->getDateStart()->toString(), - $processedPeriod->getDateEnd()->addDay(1)->toString()); + $processedPeriod->getDateStart()->toString(), + $processedPeriod->getDateEnd()->addDay(1)->toString() + ); } $sqlWhere = ""; diff --git a/plugins/PDFReports/API.php b/plugins/PDFReports/API.php index 9223074c4e..fb1c234f98 100644 --- a/plugins/PDFReports/API.php +++ b/plugins/PDFReports/API.php @@ -25,9 +25,8 @@ class Piwik_PDFReports_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/Provider/API.php b/plugins/Provider/API.php index a1f8d9815e..82b997ccd1 100644 --- a/plugins/Provider/API.php +++ b/plugins/Provider/API.php @@ -26,9 +26,8 @@ class Piwik_Provider_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/Referers/API.php b/plugins/Referers/API.php index 9f966c9ffc..f12b7ab713 100644 --- a/plugins/Referers/API.php +++ b/plugins/Referers/API.php @@ -26,8 +26,7 @@ class Piwik_Referers_API { if (self::$instance == null) { - $c = __CLASS__; - self::$instance = new $c(); + self::$instance = new self; } return self::$instance; } diff --git a/plugins/SEO/API.php b/plugins/SEO/API.php index 5759891b44..027fff3049 100644 --- a/plugins/SEO/API.php +++ b/plugins/SEO/API.php @@ -27,9 +27,8 @@ class Piwik_SEO_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/SitesManager/API.php b/plugins/SitesManager/API.php index 982f6d503a..1079ff5115 100644 --- a/plugins/SitesManager/API.php +++ b/plugins/SitesManager/API.php @@ -24,9 +24,8 @@ class Piwik_SitesManager_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/UserCountry/API.php b/plugins/UserCountry/API.php index 0480c8d1d9..cdab67c89e 100644 --- a/plugins/UserCountry/API.php +++ b/plugins/UserCountry/API.php @@ -27,9 +27,8 @@ class Piwik_UserCountry_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/UserSettings/API.php b/plugins/UserSettings/API.php index c792154602..2a97d4af09 100644 --- a/plugins/UserSettings/API.php +++ b/plugins/UserSettings/API.php @@ -25,9 +25,8 @@ class Piwik_UserSettings_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/UsersManager/API.php b/plugins/UsersManager/API.php index dce3239dca..23250b5430 100644 --- a/plugins/UsersManager/API.php +++ b/plugins/UsersManager/API.php @@ -24,9 +24,8 @@ class Piwik_UsersManager_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/VisitFrequency/API.php b/plugins/VisitFrequency/API.php index 6004fa8429..d00ca326f4 100644 --- a/plugins/VisitFrequency/API.php +++ b/plugins/VisitFrequency/API.php @@ -20,9 +20,8 @@ class Piwik_VisitFrequency_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/VisitTime/API.php b/plugins/VisitTime/API.php index 01eeab5405..917c9cc4b2 100644 --- a/plugins/VisitTime/API.php +++ b/plugins/VisitTime/API.php @@ -20,9 +20,8 @@ class Piwik_VisitTime_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/VisitorInterest/API.php b/plugins/VisitorInterest/API.php index 4dd920aeaf..78b927a9ed 100644 --- a/plugins/VisitorInterest/API.php +++ b/plugins/VisitorInterest/API.php @@ -20,9 +20,8 @@ class Piwik_VisitorInterest_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } diff --git a/plugins/VisitsSummary/API.php b/plugins/VisitsSummary/API.php index 27d0ed9fec..63f7d99693 100644 --- a/plugins/VisitsSummary/API.php +++ b/plugins/VisitsSummary/API.php @@ -20,9 +20,8 @@ class Piwik_VisitsSummary_API static public function getInstance() { if (self::$instance == null) - { - $c = __CLASS__; - self::$instance = new $c(); + { + self::$instance = new self; } return self::$instance; } |