+ // If a thumb proxy is set up for the repo, we favor that, as that will
+ // keep the request internal
+ $thumbProxyUrl = $file->getRepo()->getThumbProxyUrl();
+
+ if ( strlen( $thumbProxyUrl ) ) {
+ $scalerThumbUrl = $thumbProxyUrl . 'temp/' . $file->getUrlRel() .
+ '/' . rawurlencode( $scalerThumbName );
+ }
+