# GroupChannelCollection \`onChannelsAdded\` not trigger when user does not have any channels before

**URL:** <https://community.sendbird.com/t/groupchannelcollection-onchannelsadded-not-trigger-when-user-does-not-have-any-channels-before/4678>\
**Category:** JavaScript\
**Tags:** group-channel, chatsdk\
**Created:** [May 17, 2022, 1:02pm UTC](https://community.sendbird.com/t/groupchannelcollection-onchannelsadded-not-trigger-when-user-does-not-have-any-channels-before/4678 "2022-05-17T13:02:52Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Peter\_Cheng](https://sea2.discourse-cdn.com/flex020/user_avatar/community.sendbird.com/peter_cheng/32/1814_2.png) [@Peter\_Cheng](https://community.sendbird.com/u/Peter_Cheng)\
**Post date:** [May 17, 2022, 1:02pm UTC](https://community.sendbird.com/t/groupchannelcollection-onchannelsadded-not-trigger-when-user-does-not-have-any-channels-before/4678/1 "2022-05-17T13:02:52Z")

</div>

Hi, I’m facing a problem that the group channel collection handler not trigger properly when user does not have any joined channels before.

Steps:

1. `initialJoinedChannels` is empty
2. user join a channel
3. `onChannelsAdded` not trigger (Unexpected)
4. refresh page
5. `initialJoinedChannels` has one channel one (expected)
6. user join another channel
7. `onChannelsAdded` trigger properly (expected)

```auto
const groupChannelFilter = new GroupChannelFilter();
groupChannelFilter.includeEmpty = true;

const collection = sb.groupChannel.createGroupChannelCollection({
  filter: groupChannelFilter,
  order: GroupChannelListOrder.LATEST_LAST_MESSAGE,
  limit: PAGE_SIZE,
});

collection.setGroupChannelCollectionHandler({
  onChannelsAdded: (c, channels) => {
    console.info("On channels added", c.source);
  },
  onChannelsUpdated: (c, channels) => {
    console.info("On channels updated", c.source);
  },
  onChannelsDeleted: (c, channelIds) => {
    console.info("On channels delted", c.source);
  },
});

const initialJoinedChannels = await collection.loadMore();

```

refs @sendbird/chat": "4.0.0-beta.9
