From: Chad Horohoe Date: Fri, 21 Nov 2008 11:34:09 +0000 (+0000) Subject: Replace mkdir() in favor of wfMkdirParents(): X-Git-Tag: 1.31.0-rc.0~44233 X-Git-Url: http://git.cyclocoop.org//%27http:/code.google.com/p/ie7-js//%27?a=commitdiff_plain;h=2033b1fce5d895dca21d80326272faae236fc04c;p=lhc%2Fweb%2Fwiklou.git Replace mkdir() in favor of wfMkdirParents(): * It handles directory modes for us (rather than hardcode 0777) * It handles recursion for us --- diff --git a/maintenance/cleanupImages.php b/maintenance/cleanupImages.php index 69333fefa8..b976ba80cf 100644 --- a/maintenance/cleanupImages.php +++ b/maintenance/cleanupImages.php @@ -144,7 +144,7 @@ class ImageCleanup extends TableCleanup { __METHOD__ ); $dir = dirname( $finalPath ); if( !file_exists( $dir ) ) { - if( !mkdir( $dir, 0777, true ) ) { + if( !wfMkdirParents( $dir ) ) { $this->log( "RENAME FAILED, COULD NOT CREATE $dir" ); $db->rollback(); return;