Ver Fonte

Add sorting for delete in Search\Index

Visman há 1 ano atrás
pai
commit
e18280fbb0
1 ficheiros alterados com 4 adições e 0 exclusões
  1. 4 0
      app/Models/Search/Index.php

+ 4 - 0
app/Models/Search/Index.php

@@ -106,6 +106,10 @@ class Index extends Method
                 continue;
             }
 
+            if (\count($list) > 1) {
+                \sort($list, \SORT_NUMERIC);
+            }
+
             $vars = [
                 ':pid'  => $post->id,
                 ':subj' => 's' === $key ? 1 : 0,