aboutsummaryrefslogtreecommitdiff
path: root/advtrains_line_automation/stoprail.lua
diff options
context:
space:
mode:
authororwell96 <orwell@bleipb.de>2019-02-03 16:37:03 +0100
committerorwell96 <orwell@bleipb.de>2019-02-03 16:37:03 +0100
commitbe09acf5e2da6b71d0ba3449421ee982b2d53331 (patch)
tree85df801ffd80838b59a045de6b5101d7401d69a5 /advtrains_line_automation/stoprail.lua
parent9da148347d304ec2f26af6f813e26cb02bc6a6e7 (diff)
downloadadvtrains-be09acf5e2da6b71d0ba3449421ee982b2d53331.tar.gz
advtrains-be09acf5e2da6b71d0ba3449421ee982b2d53331.tar.bz2
advtrains-be09acf5e2da6b71d0ba3449421ee982b2d53331.zip
Minor Bugfixes
Diffstat (limited to 'advtrains_line_automation/stoprail.lua')
-rw-r--r--advtrains_line_automation/stoprail.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/advtrains_line_automation/stoprail.lua b/advtrains_line_automation/stoprail.lua
index 7ddcec6..cc2c8ac 100644
--- a/advtrains_line_automation/stoprail.lua
+++ b/advtrains_line_automation/stoprail.lua
@@ -83,7 +83,7 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
return
end
local stn = advtrains.lines.stations[stdata.stn]
- if fields.stnname and fields.stnname ~= stn.name then
+ if stn and fields.stnname and fields.stnname ~= stn.name then
if (stn.owner == pname or minetest.check_player_privs(pname, "train_admin")) then
stn.name = fields.stnname
else