PHP 8.1 deprecations

Created on 1 June 2023, over 1 year ago
Updated 4 May 2024, 8 months ago

Problem/Motivation

  • Importing throws following errors for LineIterator.php
Deprecated: Return type of Drupal\feeds_ex\File\LineIterator::rewind() should either be compatible with SplFileObject::rewind(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /app/web/modules/contrib/feeds_ex/src/File/LineIterator.php on line 36
Deprecated: Return type of Drupal\feeds_ex\File\LineIterator::valid() should either be compatible with SplFileObject::valid(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /app/web/modules/contrib/feeds_ex/src/File/LineIterator.php on line 55
Deprecated: Return type of Drupal\feeds_ex\File\LineIterator::next() should either be compatible with SplFileObject::next(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /app/web/modules/contrib/feeds_ex/src/File/LineIterator.php on line 47

Proposed resolution

Update return type to match the root method return type

πŸ› Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States hlopez

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

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

Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024