1
0
Fork 0
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:
Craig Davison 2014-11-26 22:48:43 +10:00 committed by Craig Robbins
parent 8df8554fce
commit dbae8a8854
2 changed files with 7 additions and 6 deletions

View file

@ -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