Fixing publisher filter behavior and adding tests, addressed CR comments