matchesSelector helper