From 3204c9f9a5780945d38a736a1208b988c8fc55f1 Mon Sep 17 00:00:00 2001 From: Atermonera Date: Tue, 22 Sep 2020 20:39:25 -0700 Subject: [PATCH 1/2] Fixes runtime in add_reagent() (#7676) Bad index: data["species"] when data is not a list --- code/modules/reagents/Chemistry-Holder.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/modules/reagents/Chemistry-Holder.dm b/code/modules/reagents/Chemistry-Holder.dm index 8598d54115..70bacce63f 100644 --- a/code/modules/reagents/Chemistry-Holder.dm +++ b/code/modules/reagents/Chemistry-Holder.dm @@ -115,7 +115,7 @@ for(var/datum/reagent/current in reagent_list) if(current.id == id) if(current.id == "blood") - if(!isnull(data["species"]) && !isnull(current.data["species"]) && data["species"] != current.data["species"]) // Species bloodtypes are already incompatible, this just stops it from mixing into the one already in a container. + if(LAZYLEN(data) && !isnull(data["species"]) && !isnull(current.data["species"]) && data["species"] != current.data["species"]) // Species bloodtypes are already incompatible, this just stops it from mixing into the one already in a container. continue current.volume += amount