Commit d4d3c3d9 authored by Jörn Wagner's avatar Jörn Wagner Committed by Christian Kuhn
Browse files

[TASK] Make TreeNodeCollection compatible with PHP 8

Adds the new parameter in ArrayObject::asort for PHP 8. As an additional parameter it's backwards-compatible with PHP 7.4.

Resolves: #92141
Related: #92138
Releases: master
Change-Id: I691bad5f19457b7456da1e624cf7289538317495

Tested-by: default avatarAlexander Schnitzler <>
Tested-by: default avatarTYPO3com <>
Tested-by: Christian Kuhn's avatarChristian Kuhn <>
Reviewed-by: default avatarAlexander Schnitzler <>
Reviewed-by: Christian Kuhn's avatarChristian Kuhn <>
parent 94b89adf
......@@ -41,8 +41,10 @@ class TreeNodeCollection extends \ArrayObject
* Sorts the internal nodes array
* @param int $flags Optional parameter, ignored. Added to be compatible with asort method signature in PHP 8.
public function asort()
public function asort($flags = SORT_REGULAR)
$this->uasort([$this, 'nodeCompare']);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment