Download Latest Version 2.1.0 source code.zip (22.2 kB) Google Add to Preferred Sources
Home / 1.5.1
Name Modified Size InfoDownloads / Week
Parent folder
1.5.1 source code.tar.gz 2026-09-22 28.9 kB
1.5.1 source code.zip 2026-09-22 41.7 kB
README.md 2026-09-22 1.5 kB
Totals: 3 Items   72.1 kB 0

Backward Compatibility Restoration (1.5.1)

Version 1.5.0 inadvertently introduced breaking changes to the public PHP API in a minor release (#628), including strict parameter/return type hints on public methods and RequestMethod::submit(), readonly modifiers on Response and RequestParameters, and the removal of the RequestMethod\Curl and RequestMethod\Socket wrapper classes.

What's Changed in 1.5.1

  • Restored full 1.4.2 public API compatibility (#633 by @SNO7E-G, reviewed by @acoulton):
  • Restored untyped public method signatures (with PHPDoc annotations) across ReCaptcha, Response, RequestParameters, and RequestMethod::submit().
  • Removed readonly from Response and RequestParameters so subclasses and test doubles (PHPUnit::createMock()) work as expected.
  • Restored RequestMethod\Curl and RequestMethod\Socket wrapper classes and legacy constructor parameter order (new CurlPost(?Curl $curl = null, ?string $siteVerifyUrl = null) and new SocketPost(?Socket $socket = null, ?string $siteVerifyUrl = null)).
  • Documentation & Tooling:
  • Fixed ReCaptcha::RESPONSE_KEY constant name in README.md.
  • Configured PHPStan (level: 2, treatPhpDocTypesAsCertain: false) for the 1.x compatibility line without requiring a baseline file.

Note on 2.0.0: The strict type hints, readonly DTOs, and constructor modernizations introduced in 1.5.0 have been preserved on the 2.x branch and will be released under major version 2.0.0.

Source: README.md, updated 2026-09-22