Install

Works with Drupal: ^10 || ^11 || ^12

Using Composer to manage Drupal site dependencies

Alternative installation files

Download tar.gz 132.04 KB
MD5: 4cfd6889ca4f937917d9e6526cb9802d
SHA-1: 1315afc3ee807e533f8d8a8a1e0066275ec584ce
SHA-256: 0524d5b19f871c14fdf424512ca637f4e35bbf71643f2e81842a5ba801754f55
Download zip 193.38 KB
MD5: e0d2a23ff24da29fc0e1d17bce1fab54
SHA-1: 8b81b1246a1c85099c9cbe970ac14993eba2d2e0
SHA-256: c424a26bb6c5f9ec5e0762d05599f474324ade9ddee34870fb542603ecca5219

Release notes

Drupal 12 support, including a fix for a fatal error whenever the Cloudflare API returned an error.

Requirements

  • Drupal ^10 || ^11 || ^12, PHP 8.1+.
  • Core system module only.

Fixes

  • Fatal error on Drupal 12 on every Cloudflare API failure. Drupal 12 ships Guzzle 8, which removed hasResponse() and getResponse() from RequestException. The API client called both, so a bad token, a rate limit or a 5xx from Cloudflare ended in Call to undefined method ...::hasResponse() instead of a failed purge result. The module worked while the API succeeded and died when it errored. The response is now resolved in a way that works on Guzzle 7 (Drupal 10 and 11) and Guzzle 8 (Drupal 12). No update hook is needed; the corrected code repairs existing sites.
  • Deprecation warnings on Drupal 12. The "Purge everything" confirmation form (CloudflarePurgeEverything) now declares return types on getQuestion(), getDescription() and getConfirmText(). Valid on Drupal 10, 11 and 12.

Drupal 12

  • ^12 is now declared in cloudflare_purge.info.yml and composer.json.
  • Hooks moved into src/Hook classes behind #[LegacyHook], so one codebase serves Drupal 10, 11 and 12.
  • The status report keeps its Cloudflare Purge rows on Drupal 11.3+ and 12 (through hook_runtime_requirements()), and the module no longer breaks the next module you install on Drupal 12 with Class "cloudflare_purge_requirements" does not exist.
  • Requirement severities no longer use the REQUIREMENT_* constants removed in Drupal 12.
  • The queue worker plugin carries its attribute alongside its annotation, so Drupal 10 still discovers it.
  • Library definitions no longer set version: VERSION.

After updating

Run drush cr (new hook services must be registered). This release adds no database updates.

Created by: flashwebcenter
Created on: 6 Oct 2026 at 03:21 UTC
Last updated: 6 Oct 2026 at 03:22 UTC
Bug fixes
New features

Other releases