mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 21:06:06 +00:00
add documentation and remove console logs
This commit is contained in:
@@ -33,6 +33,10 @@ export class RoomBoldSyncUseCaseService {
|
||||
this.loadHistory()
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @description listen to all incoming message and set bold to true
|
||||
*/
|
||||
private listenToIncomingMessage() {
|
||||
return this.MessageSocketRepositoryService.listenToMessages().pipe(
|
||||
filter((message) => !message?.requestId?.startsWith(InstanceId)),
|
||||
@@ -51,6 +55,10 @@ export class RoomBoldSyncUseCaseService {
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @description Listen to all update message. If the incoming updated message has readAt my me and is the last message then remove bold
|
||||
*/
|
||||
private listenToUpdateMessages() {
|
||||
return this.MessageSocketRepositoryService.listenToUpdateMessages().pipe(
|
||||
filter((message) => !message?.requestId?.startsWith(InstanceId)),
|
||||
@@ -77,6 +85,9 @@ export class RoomBoldSyncUseCaseService {
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @description set bold base on the last message on load history. If the last message has readAt by me then remove bold in case not set bold
|
||||
*/
|
||||
@XTracerAsync({name:'RoomBoldSyncUseCaseService/loadHistory', module:'chat', bugPrint: true})
|
||||
private loadHistory() {
|
||||
const regex = new RegExp("Room\\/([0-9a-fA-F]{8})-([0-9a-fA-F]{4})-([0-9a-fA-F]{4})-([0-9a-fA-F]{4})-([0-9a-fA-F]{12})\\/Messages");
|
||||
|
||||
Reference in New Issue
Block a user