From: Elliott Eggleston Date: Mon, 2 Mar 2015 18:25:25 +0000 (-0800) Subject: Only need one check for is_dir X-Git-Tag: 1.31.0-rc.0~11734^2 X-Git-Url: https://git.cyclocoop.org/%242?a=commitdiff_plain;h=7d8f8ae84df1da8bd62cb908d90346abb4ac3686;p=lhc%2Fweb%2Fwiklou.git Only need one check for is_dir It implicitly includes file_exists test. Change-Id: I25a6e609801455f2102d14035900248192e49f39 --- diff --git a/includes/GlobalFunctions.php b/includes/GlobalFunctions.php index 5232413fdd..73774334c9 100644 --- a/includes/GlobalFunctions.php +++ b/includes/GlobalFunctions.php @@ -2558,7 +2558,7 @@ function wfMkdirParents( $dir, $mode = null, $caller = null ) { wfDebug( "$caller: called wfMkdirParents($dir)\n" ); } - if ( strval( $dir ) === '' || ( file_exists( $dir ) && is_dir( $dir ) ) ) { + if ( strval( $dir ) === '' || is_dir( $dir ) ) { return true; }