@@ -15,7 +15,7 @@ discard block |
||
| 15 | 15 | final public static function chmod($path, $mode, $recursive = false, $strict = true) |
| 16 | 16 | { |
| 17 | 17 | $mode = self::fixFileModeFormat($mode); |
| 18 | - $recursive = ($recursive == false) ? '': '-R'; |
|
| 18 | + $recursive = ($recursive == false) ? '' : '-R'; |
|
| 19 | 19 | system("chmod {$recursive} {$mode} {$path} 2> /dev/null", $retval); |
| 20 | 20 | |
| 21 | 21 | if ($strict == false && $retval != 0) |
@@ -40,7 +40,7 @@ discard block |
||
| 40 | 40 | */ |
| 41 | 41 | final public static function chgrp($file, $group, $recursive = false, $strict = true) |
| 42 | 42 | { |
| 43 | - $recursive = ($recursive == false) ?'': '-R'; |
|
| 43 | + $recursive = ($recursive == false) ? '' : '-R'; |
|
| 44 | 44 | system("chgrp {$recursive} {$group} {$file} 2> /dev/null", $retval); |
| 45 | 45 | |
| 46 | 46 | if ($strict == false && $retval != 0) |
@@ -97,13 +97,11 @@ discard block |
||
| 97 | 97 | if ($GLOBALS['stderrfile'] !== null) |
| 98 | 98 | { |
| 99 | 99 | file_put_contents($GLOBALS['stderrfile'], $buffer, FILE_APPEND | LOCK_EX); |
| 100 | - } |
|
| 101 | - else |
|
| 100 | + } else |
|
| 102 | 101 | { |
| 103 | 102 | file_put_contents($GLOBALS['stdoutfile'], $buffer, FILE_APPEND | LOCK_EX); |
| 104 | 103 | } |
| 105 | - } |
|
| 106 | - else |
|
| 104 | + } else |
|
| 107 | 105 | { |
| 108 | 106 | file_put_contents($GLOBALS['stdoutfile'], $buffer, FILE_APPEND | LOCK_EX); |
| 109 | 107 | } |
@@ -119,7 +117,8 @@ discard block |
||
| 119 | 117 | */ |
| 120 | 118 | final protected function stream_to_stdout(Process $process) |
| 121 | 119 | { |
| 122 | - $process->run(function($type, $buffer) { |
|
| 120 | + $process->run(function($type, $buffer) |
|
| 121 | + { |
|
| 123 | 122 | if (Process::ERR === $type) |
| 124 | 123 | { |
| 125 | 124 | fwrite(STDERR, $buffer); |
@@ -151,7 +150,8 @@ discard block |
||
| 151 | 150 | $GLOBALS['stdoutfile'] = $stdoutfile; |
| 152 | 151 | $GLOBALS['stderrfile'] = $stderrfile; |
| 153 | 152 | |
| 154 | - $process->run(function($type, $buffer) { |
|
| 153 | + $process->run(function($type, $buffer) |
|
| 154 | + { |
|
| 155 | 155 | if (Process::ERR === $type) |
| 156 | 156 | { |
| 157 | 157 | if ($GLOBALS['stderrfile'] !== null) |