cakephp2-php8/lib/Cake
Markus Podar d201312a0e
php-8.0-compat: fix "Error: Unknown named parameter $subject"
PHP 8 added support for named parameters however will throw an error when
a named parameter, which does not exist, will be called/appears.

In this case the code uses `array_filter(compact('subject))` to conveniently
prepend `$subject` to the callback, if it's non-null.

It's then combined with `$params` but mixing a hash wih a sequential array
and then end result is `['subject' => …, ]` which then triggers this
TypeError in PHP 8.

The solution applies `array_values()` on above array as to remove the keys
and then the error disappears.

With this change, our internal test suite (2k tests) is green on both PHP8
and PHP7.4, aka this change is expecte to be backwards compatible.
2020-11-12 17:30:04 +01:00
..
Cache Fix shutdown warnings in PHP7.2+ 2019-04-16 21:23:58 -04:00
Config Merge branch '2.x' into 2.next 2017-06-26 21:51:41 -04:00
Configure Merge branch '2.x' into 2.next 2017-06-26 21:51:41 -04:00
Console Make TestShell compatible with PHP 7.4 2020-10-21 17:48:23 +00:00
Controller Improve doc block 2019-12-06 10:41:45 +01:00
Core Fix some PHP 7.3 errors 2018-11-11 16:15:55 +01:00
Error Merge branch '2.x' into 2.next 2017-06-26 21:51:41 -04:00
Event Fix invalid data type 2020-04-21 11:32:16 +02:00
I18n add fo-fo 2020-09-01 13:28:14 +02:00
Log Improve documentation 2018-10-26 14:23:30 +02:00
Model php-7.4-compact: replace deprecated curly brace offset access 2020-03-20 21:10:58 +01:00
Network Microoptimization for ServerRequest::is() and ServerRequest::isAll() (#14654) 2020-05-31 22:43:58 +05:30
Routing Fix queryString documentation 2019-02-07 14:23:56 +01:00
Test Fix failures on PHP 7.4. Run phpcs on PHP 7.0 2019-12-05 15:11:35 +02:00
TestSuite php-7.4-compact: replace deprecated curly brace offset access 2020-03-20 21:10:58 +01:00
Utility php-8.0-compat: fix "Error: Unknown named parameter $subject" 2020-11-12 17:30:04 +01:00
View Fix deprecated argument order in calls to implode() 2020-06-17 11:44:23 -06:00
basics.php Add undocumented properties (#12717) 2018-11-15 20:41:57 -05:00
bootstrap.php Replace hard coded test directory paths with constants, fixes #12636 2018-10-26 13:49:53 +02:00
LICENSE.txt Use HTTPS for the cakephp.org URL 2017-06-10 23:40:28 +02:00
VERSION.txt Update version number to 2.10.22 2020-06-06 22:16:36 -04:00