Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. BinaryFileResponse.php

function BinaryFileResponse::hasValidIfRangeHeader

1 call to BinaryFileResponse::hasValidIfRangeHeader()
BinaryFileResponse::prepare in vendor/symfony/http-foundation/BinaryFileResponse.php
Prepares the Response before it is sent to the client.

File

vendor/symfony/http-foundation/BinaryFileResponse.php, line 286

Class

BinaryFileResponse
BinaryFileResponse represents an HTTP response delivering a file.

Namespace

Symfony\Component\HttpFoundation

Code

private function hasValidIfRangeHeader(?string $header) : bool {
    if ($this->getEtag() === $header) {
        return true;
    }
    if (null === ($lastModified = $this->getLastModified())) {
        return false;
    }
    return $lastModified->format('D, d M Y H:i:s') . ' GMT' === $header;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal