|
1 | 1 | import type { Event, StreamChat } from 'stream-chat'; |
2 | 2 |
|
3 | | -import { deleteChannel } from '../../../store/apis/deleteChannel'; |
| 3 | +// import { deleteChannel } from '../../../store/apis/deleteChannel'; |
4 | 4 | // import { deleteMember } from '../../../store/apis/deleteMember'; |
5 | 5 | import { deleteMessagesForChannel } from '../../../store/apis/deleteMessagesForChannel'; |
6 | 6 | // import { updateMessage } from '../../../store/apis/updateMessage'; |
7 | | -import { upsertChannelData } from '../../../store/apis/upsertChannelData'; |
| 7 | +// import { upsertChannelData } from '../../../store/apis/upsertChannelData'; |
8 | 8 | // import { upsertChannelDataFromChannel } from '../../../store/apis/upsertChannelDataFromChannel'; |
9 | 9 | // import { upsertMembers } from '../../../store/apis/upsertMembers'; |
10 | 10 | // import { upsertReads } from '../../../store/apis/upsertReads'; |
@@ -190,32 +190,32 @@ export const handleEventToSyncDB = async (event: Event, client: StreamChat, flus |
190 | 190 | // } |
191 | 191 | // } |
192 | 192 |
|
193 | | - if ( |
194 | | - // type === 'channel.updated' || |
195 | | - // type === 'channel.visible' || |
196 | | - type === 'notification.added_to_channel' || |
197 | | - type === 'notification.message_new' |
198 | | - ) { |
199 | | - if (event.channel) { |
200 | | - return upsertChannelData({ |
201 | | - channel: event.channel, |
202 | | - flush, |
203 | | - }); |
204 | | - } |
205 | | - } |
| 193 | + // if ( |
| 194 | + // // type === 'channel.updated' || |
| 195 | + // // type === 'channel.visible' || |
| 196 | + // // type === 'notification.added_to_channel' || |
| 197 | + // type === 'notification.message_new' |
| 198 | + // ) { |
| 199 | + // if (event.channel) { |
| 200 | + // return upsertChannelData({ |
| 201 | + // channel: event.channel, |
| 202 | + // flush, |
| 203 | + // }); |
| 204 | + // } |
| 205 | + // } |
206 | 206 |
|
207 | | - if ( |
208 | | - // type === 'channel.hidden' || |
209 | | - // type === 'channel.deleted' || |
210 | | - type === 'notification.removed_from_channel' |
211 | | - ) { |
212 | | - if (event.channel) { |
213 | | - return deleteChannel({ |
214 | | - cid: event.channel.cid, |
215 | | - flush, |
216 | | - }); |
217 | | - } |
218 | | - } |
| 207 | + // if ( |
| 208 | + // // type === 'channel.hidden' || |
| 209 | + // // type === 'channel.deleted' || |
| 210 | + // type === 'notification.removed_from_channel' |
| 211 | + // ) { |
| 212 | + // if (event.channel) { |
| 213 | + // return deleteChannel({ |
| 214 | + // cid: event.channel.cid, |
| 215 | + // flush, |
| 216 | + // }); |
| 217 | + // } |
| 218 | + // } |
219 | 219 |
|
220 | 220 | if (type === 'channel.truncated') { |
221 | 221 | if (event.channel) { |
|
0 commit comments