wakuconnect-chat-sdk/packages/status-js/src/client/community/create-channel-content-topi...

16 lines
377 B
TypeScript

import { idToContentTopic } from '../../contentTopic'
export function createChannelContentTopics(
channelIds: string[],
communityPublicKey: string
) {
const channelTopics = channelIds.map(channelId => {
const id = `${communityPublicKey}${channelId}`
const channelContentTopic = idToContentTopic(id)
return channelContentTopic
})
return channelTopics
}