Adding additional validation to IgnoredWhenDetachedHandler as suggested by @yDelouis