X-Git-Url: https://git.cyclocoop.org/?a=blobdiff_plain;ds=inline;f=thumb.php;h=d53c10c93ea45ce1bad468b20130433667c0d13c;hb=a8d4bfaa838b7ba84d630bff42fa1fb32a8ac3fb;hp=9a4b332124b5708ae535365cef2ba23a353b17e7;hpb=7863ca17e2c56a413e10934109fb72b05e6a25ab;p=lhc%2Fweb%2Fwiklou.git diff --git a/thumb.php b/thumb.php index 9a4b332124..d53c10c93e 100644 --- a/thumb.php +++ b/thumb.php @@ -388,7 +388,8 @@ function wfGenerateThumbnail( File $file, array $params, $thumbName, $thumbPath $errorHtml = false; // guard thumbnail rendering with PoolCounter to avoid stampedes - // expensive files use a separate PoolCounter config so it is possible to set up a global limit on them + // expensive files use a separate PoolCounter config so it is possible + // to set up a global limit on them if ( $file->isExpensiveToThumbnail() ) { $poolCounterType = 'FileRenderExpensive'; } else { @@ -520,7 +521,8 @@ function wfExtractThumbRequestInfo( $thumbRel ) { $repo = RepoGroup::singleton()->getLocalRepo(); $hashDirReg = $subdirReg = ''; - for ( $i = 0; $i < $repo->getHashLevels(); $i++ ) { + $hashLevels = $repo->getHashLevels(); + for ( $i = 0; $i < $hashLevels; $i++ ) { $subdirReg .= '[0-9a-f]'; $hashDirReg .= "$subdirReg/"; }