Fix runtime in wires.dm when holder is null

This commit is contained in:
Bizzonium
2020-08-02 19:32:23 +03:00
parent 91d679f2ed
commit 00558f129b
+2 -2
View File
@@ -141,7 +141,7 @@ GLOBAL_LIST_INIT(wireColours, list("red", "blue", "green", "black", "orange", "b
if(..())
return 1
var/mob/L = usr
if(CanUse(L) && href_list["action"])
if(holder && CanUse(L) && href_list["action"])
var/obj/item/I = L.get_active_hand()
var/colour = lowertext(href_list["wire"])
holder.add_hiddenprint(L)
@@ -194,7 +194,7 @@ GLOBAL_LIST_INIT(wireColours, list("red", "blue", "green", "black", "orange", "b
return 1
/datum/wires/CanUseTopic(mob/user, datum/topic_state/state)
if(!CanUse(user))
if(holder && !CanUse(user))
return STATUS_CLOSE
return ..()