Simplify the ExcludePattern logic further, and explain.