Page MenuHomePhabricator

D9594.id22986.diff
No OneTemporary

D9594.id22986.diff

diff --git a/src/filesystem/Filesystem.php b/src/filesystem/Filesystem.php
--- a/src/filesystem/Filesystem.php
+++ b/src/filesystem/Filesystem.php
@@ -594,12 +594,14 @@
*
* @task directory
*/
- public static function createDirectory($path, $umask = 0777,
+ public static function createDirectory($path, $umask = null,
$recursive = false) {
$path = self::resolvePath($path);
if (is_dir($path)) {
- Filesystem::changePermissions($path, $umask);
+ if ($umask) {
+ Filesystem::changePermissions($path, $umask);
+ }
return $path;
}
@@ -626,7 +628,9 @@
// 'The parameter mode specifies the permissions to use. It is modified by
// the process's umask in the usual way: the permissions of the created
// directory are (mode & ~umask & 0777)."'
- Filesystem::changePermissions($path, $umask);
+ if ($umask) {
+ Filesystem::changePermissions($path, $umask);
+ }
return $path;
}

File Metadata

Mime Type
text/plain
Expires
Sat, Mar 29, 11:44 AM (2 w, 6 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7712442
Default Alt Text
D9594.id22986.diff (1018 B)

Event Timeline