Skip to content

Commit

Permalink
Removed parameter: player from command.execute
Browse files Browse the repository at this point in the history
  • Loading branch information
JamesClarke7283 committed Oct 16, 2023
1 parent e022994 commit 312a1b3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/os/api/cli.lua
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ function modular_computers.command.execute(...)
local def = modular_computers.internal.command.registered_commands[args[1]]
local terminal_text = ""
if def ~= nil then
local stdin, stdout, stderr, exit_code = def.func(player, #args - 1, unpack(args, 2))
local stdin, stdout, stderr, exit_code = def.func(#args - 1, unpack(args, 2))
if stdin ~= "" then
terminal_text = terminal_text .. stdin
end
Expand Down
2 changes: 1 addition & 1 deletion src/os/bin/echo.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
]]

modular_computers.command.register("echo", {
func = function(player, argc, ...)
func = function(argc, ...)
return "", table.concat({...}, " ") .. "\n", "", 0
end,
})

0 comments on commit 312a1b3

Please sign in to comment.