refactor channel operations