fix script runtime error when updating power networks

ipv6
Maikel de Vries 2016-12-25 22:13:24 +01:00
parent 7c2a4ee574
commit 84d621fc5a
1 changed files with 1 additions and 1 deletions

View File

@ -531,7 +531,7 @@ private func RefreshPowerNetwork(object network)
}
for (var link in Concatenate(network.lib_power.waiting_consumers, network.lib_power.active_consumers))
{
if (!link)
if (!link || !link.obj)
continue;
var actual_network = Library_Power->GetPowerNetwork(link.obj);
if (!actual_network || actual_network == network)