diff options
author | mattab <matthieu.aubry@gmail.com> | 2013-07-31 01:13:56 +0400 |
---|---|---|
committer | mattab <matthieu.aubry@gmail.com> | 2013-07-31 01:13:56 +0400 |
commit | 765be0dc8f92a6d4bb3e678a0c23f2d4b95e0e18 (patch) | |
tree | 3a0ae0e7334250446b687667e4d365af6975e0f4 /plugins/SegmentEditor | |
parent | 5104d94f3b2250f766b9c520e2da8da9b4cab2e9 (diff) |
Refs #3741 Resuming PHP Namespaces conversion of Piwik core, mostly finished core/ conversion
Diffstat (limited to 'plugins/SegmentEditor')
-rw-r--r-- | plugins/SegmentEditor/API.php | 10 | ||||
-rw-r--r-- | plugins/SegmentEditor/SegmentEditor.php | 1 |
2 files changed, 6 insertions, 5 deletions
diff --git a/plugins/SegmentEditor/API.php b/plugins/SegmentEditor/API.php index 884c206e78..c8bb844a09 100644 --- a/plugins/SegmentEditor/API.php +++ b/plugins/SegmentEditor/API.php @@ -135,7 +135,7 @@ class Piwik_SegmentEditor_API Piwik_PostEvent(self::DELETE_SEGMENT_EVENT, array(&$idSegment)); $segment = $this->getSegmentOrFail($idSegment); - $db = Zend_Registry::get('db'); + $db = \Zend_Registry::get('db'); $db->delete(Common::prefixTable('segment'), 'idsegment = ' . $idSegment); return true; } @@ -172,7 +172,7 @@ class Piwik_SegmentEditor_API 'ts_last_edit' => Date::now()->getDatetime(), ); - $db = Zend_Registry::get('db'); + $db = \Zend_Registry::get('db'); $db->update(Common::prefixTable("segment"), $bind, "idsegment = $idSegment" @@ -200,7 +200,7 @@ class Piwik_SegmentEditor_API $enabledAllUsers = $this->checkEnabledAllUsers($enabledAllUsers); $autoArchive = $this->checkAutoArchive($autoArchive, $idSite); - $db = Zend_Registry::get('db'); + $db = \Zend_Registry::get('db'); $bind = array( 'name' => $name, 'definition' => $definition, @@ -228,7 +228,7 @@ class Piwik_SegmentEditor_API if (!is_numeric($idSegment)) { throw new Exception("idSegment should be numeric."); } - $segment = Zend_Registry::get('db')->fetchRow("SELECT * " . + $segment = \Zend_Registry::get('db')->fetchRow("SELECT * " . " FROM " . Common::prefixTable("segment") . " WHERE idsegment = ?", $idSegment); @@ -286,7 +286,7 @@ class Piwik_SegmentEditor_API AND deleted = 0 $extraWhere ORDER BY name ASC"; - $segments = Zend_Registry::get('db')->fetchAll($sql, $bind); + $segments = \Zend_Registry::get('db')->fetchAll($sql, $bind); return $segments; } diff --git a/plugins/SegmentEditor/SegmentEditor.php b/plugins/SegmentEditor/SegmentEditor.php index 0d539b078f..5d1731c006 100644 --- a/plugins/SegmentEditor/SegmentEditor.php +++ b/plugins/SegmentEditor/SegmentEditor.php @@ -11,6 +11,7 @@ use Piwik\Common; use Piwik\Version; use Piwik\Plugin; +use Piwik\Db; /** * @package Piwik_SegmentEditor |