mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-06-14 07:25:31 +00:00
Merge pull request #3387 from PEMapModder/patch-6
Allow saving resources with parent directory being recursively created
This commit is contained in:
commit
b766b969e2
@ -202,8 +202,8 @@ abstract class PluginBase implements Plugin{
|
|||||||
}
|
}
|
||||||
|
|
||||||
$out = $this->dataFolder . $filename;
|
$out = $this->dataFolder . $filename;
|
||||||
if(!file_exists($this->dataFolder)){
|
if(!file_exists(dirname($out))){
|
||||||
mkdir($this->dataFolder, 0755, true);
|
mkdir(dirname($out), 0755, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(file_exists($out) and $replace !== true){
|
if(file_exists($out) and $replace !== true){
|
||||||
|
Loading…
x
Reference in New Issue
Block a user