mirror of
https://github.com/luanti-org/luanti.git
synced 2025-07-22 17:18:39 +00:00
Fix some undeclared global variables
This commit is contained in:
parent
8df8554fce
commit
dbae8a8854
2 changed files with 7 additions and 6 deletions
|
@ -252,7 +252,7 @@ core.register_chatcommand("clearpassword", {
|
|||
description = "set empty password",
|
||||
privs = {password=true},
|
||||
func = function(name, param)
|
||||
toname = param
|
||||
local toname = param
|
||||
if toname == "" then
|
||||
return false, "Name field required"
|
||||
end
|
||||
|
@ -426,6 +426,7 @@ local function handle_give_command(cmd, giver, receiver, stackstring)
|
|||
return false, receiver .. " is not a known player"
|
||||
end
|
||||
local leftover = receiverref:get_inventory():add_item("main", itemstack)
|
||||
local partiality
|
||||
if leftover:is_empty() then
|
||||
partiality = ""
|
||||
elseif leftover:get_count() == itemstack:get_count() then
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue