From: Jan Schneider Date: Tue, 24 Aug 2010 14:47:53 +0000 (+0200) Subject: Make Horde_Vcs_File#logs public. X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=a7618bd2d55b95986038515e569071045cfb9544;p=horde.git Make Horde_Vcs_File#logs public. --- diff --git a/framework/Vcs/lib/Horde/Vcs.php b/framework/Vcs/lib/Horde/Vcs.php index 34972aafa..c29a79b6f 100644 --- a/framework/Vcs/lib/Horde/Vcs.php +++ b/framework/Vcs/lib/Horde/Vcs.php @@ -852,7 +852,7 @@ abstract class Horde_Vcs_File /** * TODO */ - protected $_logs = array(); + public $logs = array(); /** * TODO @@ -964,10 +964,10 @@ abstract class Horde_Vcs_File */ public function queryLastLog() { - if (!isset($this->_revs[0]) || !isset($this->_logs[$this->_revs[0]])) { + if (!isset($this->_revs[0]) || !isset($this->logs[$this->_revs[0]])) { throw new Horde_Vcs_Exception('No revisions'); } - return $this->_logs[$this->_revs[0]]; + return $this->logs[$this->_revs[0]]; } /** @@ -994,7 +994,7 @@ abstract class Horde_Vcs_File break; } - uasort($this->_logs, array($this, 'sortBy' . $func)); + uasort($this->logs, array($this, 'sortBy' . $func)); return true; } @@ -1061,8 +1061,8 @@ abstract class Horde_Vcs_File public function queryLogs($rev = null) { return is_null($rev) - ? $this->_logs - : (isset($this->_logs[$rev]) ? $this->_logs[$rev] : null); + ? $this->logs + : (isset($this->logs[$rev]) ? $this->logs[$rev] : null); } /** diff --git a/framework/Vcs/lib/Horde/Vcs/Cvs.php b/framework/Vcs/lib/Horde/Vcs/Cvs.php index c05584d4f..57fc53ceb 100644 --- a/framework/Vcs/lib/Horde/Vcs/Cvs.php +++ b/framework/Vcs/lib/Horde/Vcs/Cvs.php @@ -479,7 +479,7 @@ class Horde_Vcs_File_Cvs extends Horde_Vcs_File if ($onbranch) { $this->_revs[] = $rev; - $this->_logs[$rev] = $log; + $this->logs[$rev] = $log; } $this->_accum = array(); diff --git a/framework/Vcs/lib/Horde/Vcs/Git.php b/framework/Vcs/lib/Horde/Vcs/Git.php index 2190bb31c..1c8d90869 100644 --- a/framework/Vcs/lib/Horde/Vcs/Git.php +++ b/framework/Vcs/lib/Horde/Vcs/Git.php @@ -504,7 +504,7 @@ class Horde_Vcs_File_Git extends Horde_Vcs_File } foreach ($log_list as $val) { - $this->_logs[$val] = $rep->getLogObject($this, $val); + $this->logs[$val] = $rep->getLogObject($this, $val); } } @@ -517,10 +517,10 @@ class Horde_Vcs_File_Git extends Horde_Vcs_File */ public function getHashForRevision($rev) { - if (!isset($this->_logs[$rev])) { + if (!isset($this->logs[$rev])) { throw new Horde_Vcs_Exception('This file doesn\'t exist at that revision'); } - return $this->_logs[$rev]->getHashForPath($this->queryModulePath()); + return $this->logs[$rev]->getHashForPath($this->queryModulePath()); } /** @@ -600,8 +600,8 @@ class Horde_Vcs_File_Git extends Horde_Vcs_File $rev = reset($this->_revlist[$this->_branch]); if (!is_null($rev)) { - if (isset($this->_logs[$rev])) { - return $this->_logs[$rev]; + if (isset($this->logs[$rev])) { + return $this->logs[$rev]; } } diff --git a/framework/Vcs/lib/Horde/Vcs/Svn.php b/framework/Vcs/lib/Horde/Vcs/Svn.php index 5417bab63..c91073e8e 100644 --- a/framework/Vcs/lib/Horde/Vcs/Svn.php +++ b/framework/Vcs/lib/Horde/Vcs/Svn.php @@ -315,7 +315,7 @@ class Horde_Vcs_File_Svn extends Horde_Vcs_File try { $log = $rep->getLogObject($this, null); $rev = $log->queryRevision(); - $this->_logs[$rev] = $log; + $this->logs[$rev] = $log; $this->_revs[] = $rev; } catch (Horde_Vcs_Exception $e) {}