[PHP8.1] messageDeprecated function: Return type of Drupal\fancy_file_delete\FancyFileDeleteDirectoryOnlyRecursiveFilterIterator::accept() should either be compatible with FilterIterator::accept(): bool, or the #[\ReturnTypeWillChange] attribute should be

Created on 13 May 2022, over 2 years ago
Updated 28 August 2023, over 1 year ago

Problem/Motivation

When running PHP8.1 the following error occurs on /admin/config/content/fancy_file_delete/unmanaged

Deprecated function: Return type of Drupal\fancy_file_delete\FancyFileDeleteDirectoryOnlyRecursiveFilterIterator::accept() should either be compatible with FilterIterator::accept(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice

Proposed resolution

Add the #[\ReturnTypeWillChange] attribute FancyFileDeleteDirectoryOnlyRecursiveFilterIterator::accept() for maximum PHP compatibility with both 7.4.x and 8.1.x

Remaining tasks

  1. Write a patch
  2. Review
  3. Commit

User interface changes

None.

API changes

None.

Data model changes

None.

πŸ“Œ Task
Status

Fixed

Version

2.0

Component

Code

Created by

πŸ‡³πŸ‡±Netherlands idebr

Live updates comments and jobs are added and updated live.
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