When I use the 'Array contains' action, I have to reference either the Prefab itself OR I store the Prefab into a Gameobject variable and reference that.
If I store it into a Gameobject variable and reference it, I will always find the last index of the array because every time I spawn a new prefab, it updates the Gameobject variable.
If I reference the Prefab itself, It will only find the variables of the prefab that never actually spawned into the scene.
I am not sure if I'm doing what you suggested the wrong way, but I did try and it doesn't seem to be working.
Maybe someone can offer some advice as to what I may be doing wrong. I will post images if you need clarity.
Thanks