From 77fd3a7e5fb1fab815c8750cb3a4b0f3fefca15f Mon Sep 17 00:00:00 2001 From: Martin Ambrus Date: Sat, 4 Nov 2017 22:03:33 +0100 Subject: [PATCH] refactor: online users in Admin sorted by 1) access, 2) lastupdate --- GameEngine/Admin/database.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/GameEngine/Admin/database.php b/GameEngine/Admin/database.php index 6d852d84..ab07312a 100755 --- a/GameEngine/Admin/database.php +++ b/GameEngine/Admin/database.php @@ -271,7 +271,7 @@ class adm_DB { function getUserActive() { $time = time() - (60*5); - $q = "SELECT * FROM ".TB_PREFIX."users where timestamp > $time and username != 'support'"; + $q = "SELECT * FROM ".TB_PREFIX."users where timestamp > $time and username != 'support' ORDER BY access DESC, lastupdate DESC"; $result = mysqli_query($this->connection, $q); return $this->mysqli_fetch_all($result); }