Fix check for cache hit.

Compare to None!