FIX: Null check in array contains function, fixes crashes with empty arrays