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

Breadcrumb

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

function Store::unlock

Releases the lock for the given Request.

Return value

bool False if the lock file does not exist or cannot be unlocked, true otherwise

Overrides StoreInterface::unlock

File

vendor/symfony/http-kernel/HttpCache/Store.php, line 99

Class

Store
Store implements all the logic for storing cache metadata (Request and Response headers).

Namespace

Symfony\Component\HttpKernel\HttpCache

Code

public function unlock(Request $request) : bool {
    $key = $this->getCacheKey($request);
    if (isset($this->locks[$key])) {
        flock($this->locks[$key], \LOCK_UN);
        fclose($this->locks[$key]);
        unset($this->locks[$key]);
        return true;
    }
    return false;
}

API Navigation

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