Deprecated function create_function()

Created on 28 August 2018, almost 6 years ago
Updated 9 January 2024, 6 months ago

In filebrowser/src/Presentation.php there are two calls for create_function(). This function has been deprecated as of PHP 7.2 and they should be replaced. Reference

// Line 139
$sorter = create_function('$a,$b', $code);
        if (!empty($just_folders)) {
          usort($just_folders, $sorter);
          if ($table_sort['sort'] == 'asc') {
            $just_folders = array_reverse($just_folders, true);
          }
        }
        if (!empty($just_files)) {
          usort($just_files, create_function('$a,$b', $code)); // Line 147
          if ($table_sort['sort'] == 'asc') {
            $just_files = array_reverse($just_files, true);
          }
        }
      }
    }
πŸ› Bug report
Status

Fixed

Version

3.5

Component

Miscellaneous

Created by

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.

No activities found.

Production build 0.69.0 2024