mirror of
https://gitee.com/hyperf/hyperf.git
synced 2024-11-30 02:37:58 +08:00
Fixed undefined variable argv (#3295)
* Fixed undefined variable argv * Update PharBuilder.php
This commit is contained in:
parent
d465da34d4
commit
9678155127
@ -192,13 +192,14 @@ class PharBuilder
|
||||
return <<<EOD
|
||||
<?php
|
||||
\$mountLink = ["{$mountLink}"];
|
||||
array_walk(\$mountLink, function (\$item){
|
||||
\$file = realpath(\$argv[0]).'/'.\$item;
|
||||
\$path = dirname(realpath(\$argv[0]));
|
||||
array_walk(\$mountLink, function (\$item) use (\$path) {
|
||||
\$file = \$path . '/' . \$item;
|
||||
if(!file_exists(\$file)){
|
||||
if(rtrim(\$item, '/')!=\$item){
|
||||
mkdir(\$file, 0777, true);
|
||||
@mkdir(\$file, 0777, true);
|
||||
}else{
|
||||
file_exists(dirname(\$file)) || mkdir(dirname(\$file), 0777, true);
|
||||
file_exists(dirname(\$file)) || @mkdir(dirname(\$file), 0777, true);
|
||||
file_put_contents(\$file,"");
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user