Przeglądaj źródła

Use keyword "static" (#4436)

static closure
Luc SANCHEZ 3 lat temu
rodzic
commit
85991d1c5c
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      app/Services/ImportService.php

+ 1 - 1
app/Services/ImportService.php

@@ -70,7 +70,7 @@ class FreshRSS_Import_Service {
 		$limits = FreshRSS_Context::$system_conf->limits;
 		$limits = FreshRSS_Context::$system_conf->limits;
 
 
 		//Sort with categories first
 		//Sort with categories first
-		usort($opml_elements, function ($a, $b) {
+		usort($opml_elements, static function ($a, $b) {
 			return strcmp(
 			return strcmp(
 				(isset($a['xmlUrl']) ? 'Z' : 'A') . (isset($a['text']) ? $a['text'] : ''),
 				(isset($a['xmlUrl']) ? 'Z' : 'A') . (isset($a['text']) ? $a['text'] : ''),
 				(isset($b['xmlUrl']) ? 'Z' : 'A') . (isset($b['text']) ? $b['text'] : ''));
 				(isset($b['xmlUrl']) ? 'Z' : 'A') . (isset($b['text']) ? $b['text'] : ''));