Change the get channels list over to the model

The getsharedchannels and getnickjoinedchannels functions were
identical, and getsharedchannels was completely unused. I took
out the extra function, and ported the remaining two.