php8 compatibility, call_user_func_array()

Created on 14 December 2022, over 2 years ago
Updated 4 April 2023, about 2 years ago

Problem/Motivation

In php 8.0.0 there was a change to call_user_func_array() which causes error on this module within the shs_json() function:

args keys will now be interpreted as parameter names, instead of being silently ignored.

Steps to reproduce

Try to use the "add new item" functionality to add a new term, and when saving that term the ajax call will fail.

Proposed resolution

Call array_values() on the keyed array

πŸ› Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States cYu

Live updates comments and jobs are added and updated live.
  • PHP 8.0

    The issue particularly affects sites running on PHP version 8.0.0 or later.

  • PHP 8.1

    The issue particularly affects sites running on PHP version 8.1.0 or later.

  • PHP 8.2

    The issue particularly affects sites running on PHP version 8.2.0 or later.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024