setting state when channel's created