From cf11f914a72489321bd2065782af3c3ea4900b10 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Fri, 29 Jan 2021 10:13:14 +0100 Subject: Make Psalm happy Signed-off-by: Joas Schilling --- lib/private/Comments/Comment.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/private/Comments/Comment.php b/lib/private/Comments/Comment.php index c838e9571c6..e2d32e74850 100644 --- a/lib/private/Comments/Comment.php +++ b/lib/private/Comments/Comment.php @@ -233,7 +233,9 @@ class Comment implements IComment { return []; } $uids = array_unique($mentions[0]); - usort($uids, 'mb_strlen'); + usort($uids, static function($uid1, $uid2) { + return mb_strlen($uid2) <=> mb_strlen($uid1); + }); $result = []; foreach ($uids as $uid) { $cleanUid = trim(substr($uid, 1), '"'); -- cgit v1.2.3