making bonjour() more functional