if ( $file && $this->filterItem( $file, $shared ) ) {
$filename = $file->getLocalRefPath();
$rel = wfRelativePath( $filename, $this->mBasePath );
if ( $file && $this->filterItem( $file, $shared ) ) {
$filename = $file->getLocalRefPath();
$rel = wfRelativePath( $filename, $this->mBasePath );