Selaa lähdekoodia

PHP Deprecated: Automatic conversion of false to array is deprecated in C:\MyPrograms\OSPanel\domains\enginegp.local\system\library\system.php on line 60

Sergei Solovev 2 vuotta sitten
vanhempi
commit
e4e03e21af
1 muutettua tiedostoa jossa 5 lisäystä ja 1 poistoa
  1. 5 1
      system/library/system.php

+ 5 - 1
system/library/system.php

@@ -50,10 +50,14 @@
             return NULL;
         }
 
-        public static function users($users = [], $user = false, $authkey = false, $del = false)
+        public static function users($users, $user, $authkey, $del = false)
         {
             global $mcache;
 
+            if (!is_array($users) || empty($users)) {
+                $users = [];
+            }
+
             if($del)
                 unset($users[md5($user['login'].$user['authkey'].$user['passwd'])]);
             else