This fixes #8335.  It was only checking if the cache was an array, not if it was empty.  It is now checking if the array is emtpy, and saying that is a cache miss.