channel joining refactoring