Skip to content

Commit

Permalink
Fix server console database checking
Browse files Browse the repository at this point in the history
  • Loading branch information
Seef0x authored and FPtje committed Dec 29, 2024
1 parent d4dba18 commit 251b843
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gamemode/modules/base/sh_util.lua
Original file line number Diff line number Diff line change
Expand Up @@ -381,13 +381,13 @@ if CLIENT then net.Receive("DarkRP_databaseCheckMessage", fc{print, net.ReadStri

local function checkDatabase(ply)
local dbFile = SERVER and "sv.db" or "cl.db"
local display = (CLIENT or ply == game.GetWorld() or not IsValid(ply)) and print or function(msg)
local display = (CLIENT or not IsValid(ply)) and print or function(msg)
net.Start("DarkRP_databaseCheckMessage")
net.WriteString(msg)
net.Send(ply)
end

if SERVER and IsValid(ply) and ply ~= game.GetWorld() and not ply:IsSuperAdmin() then
if SERVER and IsValid(ply) and not ply:IsSuperAdmin() then
display("You must be superadmin")
return
end
Expand Down

0 comments on commit 251b843

Please sign in to comment.