code: public function getType(bool $withEncoding = false): string
      {
          $this->checkFileReadPermissions();
  
          if (null !== $mime = $this->storage->getFileType($withEncoding)) {
              return $mime;
          }
  
          throw new UnexpectedValueException('unable to determin files content-type', 500);
      }
docs: guess content-type (mime) of storage
  @param  bool $withEncoding
  @return string
  @throws UnexpectedValueException|FileNotFoundException|AccessDeniedException