Problem/Motivation
Two depreciated functions
Deprecated function: fgetcsv(): the $escape parameter must be provided as its default value will change in Drupal\file_table_formatter\FileTableFormatterProcessor->getTableDataFromFile() (line 19 of web/modules/contrib/file_table_formatter/src/FileTableFormatterProcessor.php)
Deprecated function: Drupal\file_table_formatter\FileTableData::__construct(): Implicitly marking parameter $item as nullable is deprecated, the explicit nullable type must be used instead in include() (line 576 of /home/ipmsusa3/public_html/drupal11/vendor/composer/ClassLoader.php)
Steps to reproduce
Use module on Drupal 11 with PHP8.4
Visit page using CSV to table
Proposed resolution
In web/modules/contrib/file_table_formatter/src/FileTableFormatterProcessor.php change line 19 to
while (($row = fgetcsv($fhandle, NULL, ',', '"', '\\')) !== FALSE) {
In web/modules/contrib/file_table_formatter/src/FileTableData.php change __construct line to
public function __construct(File $file, ?FileItem $item = NULL, ?array $rows = NULL, ?array $header = NULL, $title = NULL) {
Issue fork file_table_formatter-3630187
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
ankit_kumarComment #4
ankit_kumarI have created an MR. Please review once
Thank you!