implemented the getChannels method