Tarray crashes project when adding 6th element

My project keeps crashing when a sixth element is added to the array. At first I was using tarray’s Add() function, but noticed the max size wasn’t being increased when reaching the max and stayed at max of 4. I switched to the Push() function and now the max is increased to 22, but it still crashes. The sixth element seems to be getting a null address and I’m not sure how to fix this.

TArray customers;

ACustomer* customer = (ACustomer*)GetWorld()->SpawnActor(ACustomer::StaticClass());

customers.Push(customer);