PHP 8.1: Automatic conversion of false to array is deprecated

Created on 12 June 2024, 5 months ago
Updated 20 June 2024, 5 months ago

Using this module on a site with PHP 8.1 I'm getting the following error:

Deprecated function: Automatic conversion of false to array is deprecated in err_translation_fixes_entity_revision_create() (line 157 of modules/contrib/err_translation_fixes/err_translation_fixes.module).
err_translation_fixes_entity_revision_create(Object, Object, NULL)

This is the offending piece of code:
$ids[] = $new_revision->id();

Checking $ids is an array before adding the new revision ID to it should resolve this issue, I believe.

๐Ÿ› Bug report
Status

Needs review

Version

1.0

Component

Code

Created by

๐Ÿ‡ฌ๐Ÿ‡งUnited Kingdom a.hover

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024