Fix for None type in cache
More cache fixes