Skip to content

Commit fee69b1

Browse files
authored
Restrict command execution to server console (#2)
1 parent 9638e91 commit fee69b1

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

lua/azlink/azlink.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
AZLINK_VERSION = "1.0.0"
1+
AZLINK_VERSION = "1.0.1"
22

33
AzLink = AzLink or { }
44
AzLink.lastSent = 0

lua/azlink/commands/azlink_command.lua

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,12 @@
88
end )
99
end
1010

11-
concommand.Add( "azlink", function( _, _, args )
11+
concommand.Add( "azlink", function( ply, _, args )
12+
if IsValid( ply ) then
13+
ply:PrintMessage( HUD_PRINTCONSOLE, "This command must be executed from the server console." )
14+
return
15+
end
16+
1217
if args[2] == "setup" then
1318
if args[3] == nil or args[4] == nil then
1419
AzLink.Logger:Error( "You must first add this server in your Azuriom admin dashboard, in the 'Servers' section." )

0 commit comments

Comments
 (0)