merging latest master
[lhc/web/wiklou.git] / includes / media / SVG.php
index 9c8fc5e..9846c71 100644 (file)
@@ -108,7 +108,6 @@ class SvgHandler extends ImageHandler {
                $clientHeight = $params['height'];
                $physicalWidth = $params['physicalWidth'];
                $physicalHeight = $params['physicalHeight'];
-               $srcPath = $image->getLocalRefPath();
 
                if ( $flags & self::TRANSFORM_LATER ) {
                        return new ThumbnailImage( $image, $dstUrl, $clientWidth, $clientHeight, $dstPath );
@@ -119,6 +118,7 @@ class SvgHandler extends ImageHandler {
                                wfMsg( 'thumbnail_dest_directory' ) );
                }
 
+               $srcPath = $image->getLocalRefPath();
                $status = $this->rasterize( $srcPath, $dstPath, $physicalWidth, $physicalHeight );
                if( $status === true ) {
                        return new ThumbnailImage( $image, $dstUrl, $clientWidth, $clientHeight, $dstPath );