Permalink
Browse files

Merge pull request #2 from longkey1/fix_local-pear

Fixed timing of set "binPath"
  • Loading branch information...
2 parents 12b3220 + 02c8a7d commit 79208b6cf9e1c95fed148a6eeb9056b97248018d @k1LoW committed May 23, 2012
Showing with 4 additions and 3 deletions.
  1. +4 −3 vendors/shells/pear_local.php
@@ -21,14 +21,15 @@ class PearLocalShell extends Shell {
function main(){
$this->_setArgs();
+ if (file_exists($this->baseDir . 'pear' . DS . 'bin' . DS . 'pear')) {
+ $this->binPath = $this->baseDir . 'pear' . DS . 'bin' . DS . 'pear';
+ }
+
if (!file_exists($this->baseDir . 'pear.conf')) {
$this->init();
}
if (!empty($this->args)) {
- if (file_exists($this->baseDir . 'pear' . DS . 'bin' . DS . 'pear')) {
- $this->binPath = $this->baseDir . 'pear' . DS . 'bin' . DS . 'pear';
- }
$command = $this->binPath . ' -c ' . $this->baseDir . 'pear.conf ' . implode(' ' , $this->args);
system($command);
}

0 comments on commit 79208b6

Please sign in to comment.