Made channel creation generic.