a minor tweak to my previous patch, handle the invalidation case