/**
  * This method will be called be the signal slot for retrieving the public URL
  * of a file.
  *
  * If the processed file was not modified (the original file is used) and if
  * that file comes from the storage using the Remote driver the public
  * URL will be modified to read the image from the remote server.
  *
  * @param \TYPO3\CMS\Core\Resource\ResourceStorage $resourceStorage
  * @param \TYPO3\CMS\Core\Resource\Driver\DriverInterface $driver
  * @param \TYPO3\CMS\Core\Resource\ResourceInterface $resourceObject
  * @param bool $relativeToCurrentScript
  * @param $urlData
  */
 public function adjustPublicUrlForProcessedFiles($resourceStorage, $driver, $resourceObject, $relativeToCurrentScript, $urlData)
 {
     if (!$resourceObject instanceof ProcessedFile) {
         return;
     }
     if (!$resourceObject->usesOriginalFile()) {
         return;
     }
     $originalDriver = $this->getDriver($resourceObject->getOriginalFile()->getStorage());
     if (!$originalDriver instanceof RemoteDriver) {
         return;
     }
     $urlData['publicUrl'] = $resourceObject->getOriginalFile()->getPublicUrl($relativeToCurrentScript);
 }