fix dumb bug in channel switching code