refactor spout emit