Skip to content

Commit

Permalink
Issue #2: PHP 8.x compatibility.
Browse files Browse the repository at this point in the history
Fixes #2.
  • Loading branch information
laryn committed Nov 29, 2022
1 parent 7a891e8 commit f052d27
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions switch.module
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,8 @@ function switch_element_info() {
/**
* Element value callback.
*/
function switch_value_callback($element, $input = FALSE, &$form_state) {
if ($input !== FALSE) {
function switch_value_callback($element, $input, &$form_state) {
if (empty($input) || $input !== FALSE) {
if (empty($input)) {
return 0;
}
Expand Down

0 comments on commit f052d27

Please sign in to comment.