More functional DOM filter