concrete/src/Entity/File/Version.php
public function updateThumbnailStorageLocation($type, StorageLocation $location)
    {
        if (!($type instanceof ThumbnailTypeVersion)) {
            $type = ThumbnailTypeVersion::getByHandle($type);
        }
        $fsl = $this->getFile()->getFileStorageLocationObject()->getFileSystemObject();
        $path = $type->getFilePath($this);
        $manager = new MountManager([
            'current' => $fsl,
            'new' => $location->getFileSystemObject(),
        ]);
        try {
            $manager->move('current://' . $path, 'new://' . $path);
        } catch (FileNotFoundException $e) {
        }
    }
public function updateThumbnailStorageLocation($type, StorageLocation $location)
    {
        if (!($type instanceof ThumbnailTypeVersion)) {
            $type = ThumbnailTypeVersion::getByHandle($type);
        }
        $fsl = $this->getFile()->getFileStorageLocationObject()->getFileSystemObject();
        $path = $type->getFilePath($this);
        $manager = new MountManager([
            'current' => $fsl,
            'new' => $location->getFileSystemObject(),
        ]);
        try {
            $manager->move('current://' . $path, 'new://' . $path);
        } catch (FileNotFoundException $e) {
        }
    }
public function updateThumbnailStorageLocation ( $ type , StorageLocation $ location ) { if ( ! ( $ type instanceof ThumbnailTypeVersion ) ) { $ type = ThumbnailTypeVersion :: getByHandle ( $ type ) ; } $ fsl = $ this -> getFile ( ) -> getFileStorageLocationObject ( ) -> getFileSystemObject ( ) ; $ path = $ type -> getFilePath ( $ this ) ; $ manager = new MountManager ( [ 'current' => $ fsl , 'new' => $ location -> getFileSystemObject ( ) , ] ) ; try { $ manager -> move ( 'current://' . $ path , 'new://' . $ path ) ; } catch ( FileNotFoundException $ e ) { } }
Move the thumbnail of a specific thumbnail type version to a new storage location.

@param \Concrete\Core\File\Image\Thumbnail\Type\Version|string $type the thumbnail type version (or its handle)
@param StorageLocation $location The destination storage location
Move the thumbnail of a specific thumbnail type version to a new storage location .