Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15449704
D9594.id22986.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1018 B
Referenced Files
None
Subscribers
None
D9594.id22986.diff
View Options
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
Details
Attached
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)
Attached To
Mode
D9594: Don't create directories as `0777` by default.
Attached
Detach File
Event Timeline
Log In to Comment