public function handle($file)
    {
        if (!$mime = $this->getMimeForEmit($file->getExtension())) {
            return $file;
        }
        if (!$file_loc = $file->getLocation()) {
            return $file;
        }
        $file->setMime($mime);
        $file->setFound();
        $fp   = fopen($file_loc, 'r');
        $file->setResource($fp);

        return $file;
    }
public function handle($file)
    {
        if (!$mime = $this->getMimeForEmit($file->getExtension())) {
            return $file;
        }
        if (!$file_loc = $file->getLocation()) {
            return $file;
        }
        $file->setMime($mime);
        $file->setFound();
        $fp   = fopen($file_loc, 'r');
        $file->setResource($fp);

        return $file;
    }
public function handle ( $ file ) { if ( ! $ mime = $ this -> getMimeForEmit ( $ file -> getExtension ( ) ) ) { return $ file ; } if ( ! $ file_loc = $ file -> getLocation ( ) ) { return $ file ; } $ file -> setMime ( $ mime ) ; $ file -> setFound ( ) ; $ fp = fopen ( $ file_loc , 'r' ) ; $ file -> setResource ( $ fp ) ; return $ file ; }
handles a file with proper extension such as gif, js, etc.

@param FileInfo $file
@return FileInfo
handles a file with proper extension such as gif js etc .