From d0ed9adec8084b193c3429b664a408b2a3f6b71c Mon Sep 17 00:00:00 2001 From: Christian Weiske Date: Sun, 17 Mar 2013 22:22:16 +0100 Subject: remove php4-style object reference passing --- src/SemanticScuttle/Service/TagCache.php | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'src/SemanticScuttle/Service/TagCache.php') diff --git a/src/SemanticScuttle/Service/TagCache.php b/src/SemanticScuttle/Service/TagCache.php index b0ddfa6..0fdb986 100644 --- a/src/SemanticScuttle/Service/TagCache.php +++ b/src/SemanticScuttle/Service/TagCache.php @@ -72,7 +72,7 @@ class SemanticScuttle_Service_TagCache extends SemanticScuttle_DbService $query.= " AND uId = " . intval($uId); //die($query); - if (! ($dbresult =& $this->db->sql_query($query)) ){ + if (! ($dbresult = $this->db->sql_query($query)) ){ message_die(GENERAL_ERROR, 'Could not get related tags', '', __LINE__, __FILE__, $query, $this->db); return false; } @@ -101,7 +101,7 @@ class SemanticScuttle_Service_TagCache extends SemanticScuttle_DbService $values = array('tag1' => $tag1, 'tag2' => $tag2, 'relationType'=> '>', 'uId'=> $uId); $query = 'INSERT INTO '. $this->getTableName() .' '. $this->db->sql_build_array('INSERT', $values); //die($query); - if (!($dbresult =& $this->db->sql_query($query))) { + if (!($dbresult = $this->db->sql_query($query))) { $this->db->sql_transaction('rollback'); message_die(GENERAL_ERROR, 'Could not add tag cache inference', '', __LINE__, __FILE__, $query, $this->db); return false; @@ -122,7 +122,7 @@ class SemanticScuttle_Service_TagCache extends SemanticScuttle_DbService $query.= ' AND relationType = ">"'; $query.= strlen($uId)>0 ? ' AND uId = ' . intval($uId) : ''; - if (!($dbresult =& $this->db->sql_query($query))) { + if (!($dbresult = $this->db->sql_query($query))) { message_die(GENERAL_ERROR, 'Could not remove tag cache inference', '', __LINE__, __FILE__, $query, $this->db); return false; } @@ -215,7 +215,7 @@ class SemanticScuttle_Service_TagCache extends SemanticScuttle_DbService $values = array('tag1' => $tag1, 'tag2' => $tag2, 'relationType'=> '=', 'uId'=> $uId); $query = 'INSERT INTO '. $this->getTableName() .' '. $this->db->sql_build_array('INSERT', $values); //die($query); - if (!($dbresult =& $this->db->sql_query($query))) { + if (!($dbresult = $this->db->sql_query($query))) { $this->db->sql_transaction('rollback'); message_die(GENERAL_ERROR, 'Could not add tag cache synonymy', '', __LINE__, __FILE__, $query, $this->db); return false; @@ -232,7 +232,7 @@ class SemanticScuttle_Service_TagCache extends SemanticScuttle_DbService $query.= ' AND relationType = "="'; $query.= ' AND uId = ' . intval($uId); - if (!($dbresult =& $this->db->sql_query($query))) { + if (!($dbresult = $this->db->sql_query($query))) { message_die(GENERAL_ERROR, 'Could not remove tag cache inference', '', __LINE__, __FILE__, $query, $this->db); return false; } @@ -295,7 +295,7 @@ class SemanticScuttle_Service_TagCache extends SemanticScuttle_DbService $query.= " AND uId = " . intval($uId); //die($query); - if (! ($dbresult =& $this->db->sql_query($query)) ){ + if (! ($dbresult = $this->db->sql_query($query)) ){ message_die(GENERAL_ERROR, 'Could not get related tags', '', __LINE__, __FILE__, $query, $this->db); return false; } @@ -323,7 +323,7 @@ class SemanticScuttle_Service_TagCache extends SemanticScuttle_DbService $query.= " AND uId = " . intval($uId); $query.= $tagExcepted!=''?" AND tag2!='" . $this->db->sql_escape($tagExcepted) . "'" : ''; - if (! ($dbresult =& $this->db->sql_query($query)) ){ + if (! ($dbresult = $this->db->sql_query($query)) ){ message_die(GENERAL_ERROR, 'Could not get related tags', '', __LINE__, __FILE__, $query, $this->db); return false; } @@ -371,7 +371,7 @@ class SemanticScuttle_Service_TagCache extends SemanticScuttle_DbService function deleteByUser($uId) { $query = 'DELETE FROM '. $this->getTableName() .' WHERE uId = '. intval($uId); - if (!($dbresult = & $this->db->sql_query($query))) { + if (!($dbresult = $this->db->sql_query($query))) { message_die(GENERAL_ERROR, 'Could not delete user tags cache', '', __LINE__, __FILE__, $query, $this->db); return false; } -- cgit v1.2.3