Should be the last of the 0777's :)
* Use wfMkdirParents() instead of mkdir() with a recursive argument. * Also, allow $wgDirectoryMode take over, instead of hardcoding 0777. * +formatting
This commit is contained in:
parent
1a0017a76f
commit
d3116f845d
2 changed files with 3 additions and 3 deletions
|
|
@ -123,7 +123,7 @@ class FileStore {
|
|||
} else {
|
||||
if( !file_exists( dirname( $destPath ) ) ) {
|
||||
wfSuppressWarnings();
|
||||
$ok = mkdir( dirname( $destPath ), 0777, true );
|
||||
$ok = wfMkdirParents( dirname( $destPath ) );
|
||||
wfRestoreWarnings();
|
||||
|
||||
if( !$ok ) {
|
||||
|
|
|
|||
|
|
@ -110,7 +110,7 @@ class MessageCache {
|
|||
global $wgLocalMessageCache;
|
||||
|
||||
$filename = "$wgLocalMessageCache/messages-" . wfWikiID() . "-$code";
|
||||
wfMkdirParents( $wgLocalMessageCache, 0777 ); // might fail
|
||||
wfMkdirParents( $wgLocalMessageCache ); // might fail
|
||||
|
||||
wfSuppressWarnings();
|
||||
$file = fopen( $filename, 'w' );
|
||||
|
|
@ -131,7 +131,7 @@ class MessageCache {
|
|||
|
||||
$filename = "$wgLocalMessageCache/messages-" . wfWikiID() . "-$code";
|
||||
$tempFilename = $filename . '.tmp';
|
||||
wfMkdirParents( $wgLocalMessageCache, 0777 ); // might fail
|
||||
wfMkdirParents( $wgLocalMessageCache ); // might fail
|
||||
|
||||
wfSuppressWarnings();
|
||||
$file = fopen( $tempFilename, 'w');
|
||||
|
|
|
|||
Loading…
Reference in a new issue