diff --git a/code/__HELPERS/_lists.dm b/code/__HELPERS/_lists.dm index 918428daf77..361bd10f329 100644 --- a/code/__HELPERS/_lists.dm +++ b/code/__HELPERS/_lists.dm @@ -403,10 +403,8 @@ * Returns TRUE if the list had nulls, FALSE otherwise **/ /proc/list_clear_nulls(list/list_to_clear) - var/start_len = list_to_clear.len - var/list/new_list = new(start_len) - list_to_clear -= new_list - return list_to_clear.len < start_len + return (list_to_clear.RemoveAll(null) > 0) + /** * Removes any empty weakrefs from the list