Skip to content

Fixes runtime on returnToPool being given a null argument.

Rob Nelson requested to merge pull/4566/Fix-ReturnToPoolRuntime into Bleeding-Edge

Created by: gbasood

istype checks for null (sometimes), but in the case of an argument like null.loc, it doesn't. This causes a runtime error when returnToPool is given a null argument.

Code I used to test this in an empty project:

client/New()
    ..()
    var/mob/test = new
    del(test)
    world << istype(test.loc, /mob) //Runtime here

Merge request reports