πŸ‡ΊπŸ‡ΈUnited States @SKrossa

Account created on 6 February 2008, almost 17 years ago
#

Recent comments

πŸ‡ΊπŸ‡ΈUnited States SKrossa

The patch in #4 may cause issues if the function is called by another module, as the variables would be in the wrong order.

Based on info at Migrating from PHP 7.4.x to PHP 8.0.x on this deprecated feature (https://www.php.net/manual/en/migration80.deprecated.php), "If a parameter with a default value is followed by a required parameter, the default value has no effect. This is deprecated as of PHP 8.0.0 and can generally be resolved by dropping the default value, without a change in functionality"

So the. patch should simply change

function switch_value_callback($element, $input = FALSE, &$form_state){

to

function switch_value_callback($element, $input, &$form_state){

And it would function just the same as before, as in PHP 7.4 the default value of FALSE was already being ignored, anyway.

I will try to create a patch that does this later (when I have a bit more time to figure out how one does that!)

Production build 0.71.5 2024